summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthieu MOREL <mmorel-35@users.noreply.github.com>2022-01-04 15:19:28 +0100
committerGitHub <noreply@github.com>2022-01-04 16:19:28 +0200
commitd5a3b3f5ec879ac596d70036551a3e716b52656d (patch)
treed1cc6e73f91d4b75c73de34bec17c4cda551fbad
parentc57e41c029ba45b0ebb3fdd9474e202cdef92767 (diff)
downloadredis-d5a3b3f5ec879ac596d70036551a3e716b52656d.tar.gz
Setup dependabot for github-actions and codespell (#9857)
This sets up dependabot to check weekly updates for pip and github-actions dependencies. If it finds an update it will create a PR to update the dependency. More information can be found here It includes the update of: * vmactions/freebsd-vm from 0.1.4 to 0.1.5 * codespell from 2.0.0 to 2.1.0 Also includes spelling fixes found by the latest version of codespell. Includes a dedicated .codespell folder so dependabot can read a requirements.txt file and every files dedicated to codespell can be grouped in the same place Co-Authored-By: Matthieu MOREL <mmorel-35@users.noreply.github.com> Co-Authored-By: MOREL Matthieu <matthieu.morel@cnp.fr>
-rw-r--r--.codespell/.codespellrc (renamed from .github/.codespellrc)2
-rw-r--r--.codespell/requirements.txt1
-rw-r--r--.codespell/wordlist.txt (renamed from .github/wordlist.txt)3
-rw-r--r--.github/dependabot.yml15
-rw-r--r--.github/workflows/daily.yml2
-rw-r--r--.github/workflows/spell-check.yml11
-rw-r--r--src/db.c2
-rw-r--r--src/module.c2
-rw-r--r--src/replication.c2
-rw-r--r--src/server.h2
10 files changed, 33 insertions, 9 deletions
diff --git a/.github/.codespellrc b/.codespell/.codespellrc
index 6cc43b26e..75b925742 100644
--- a/.github/.codespellrc
+++ b/.codespell/.codespellrc
@@ -2,4 +2,4 @@
quiet-level = 2
count =
skip = ./deps,./src/crc16_slottable.h,tmp*,./.git,./lcov-html
-ignore-words = ./.github/wordlist.txt
+ignore-words = ./.codespell/wordlist.txt
diff --git a/.codespell/requirements.txt b/.codespell/requirements.txt
new file mode 100644
index 000000000..2e904927e
--- /dev/null
+++ b/.codespell/requirements.txt
@@ -0,0 +1 @@
+codespell==2.1.0
diff --git a/.github/wordlist.txt b/.codespell/wordlist.txt
index 88fde5909..1ab16276a 100644
--- a/.github/wordlist.txt
+++ b/.codespell/wordlist.txt
@@ -13,4 +13,5 @@ smove
te
tre
cancelability
-ist \ No newline at end of file
+ist
+statics
diff --git a/.github/dependabot.yml b/.github/dependabot.yml
new file mode 100644
index 000000000..f00019d2e
--- /dev/null
+++ b/.github/dependabot.yml
@@ -0,0 +1,15 @@
+# To get started with Dependabot version updates, you'll need to specify which
+# package ecosystems to update and where the package manifests are located.
+# Please see the documentation for all configuration options:
+# https://help.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
+
+version: 2
+updates:
+ - package-ecosystem: github-actions
+ directory: /
+ schedule:
+ interval: weekly
+ - package-ecosystem: pip
+ directory: /.codespell
+ schedule:
+ interval: weekly
diff --git a/.github/workflows/daily.yml b/.github/workflows/daily.yml
index 5cc7fbd22..88e31f52a 100644
--- a/.github/workflows/daily.yml
+++ b/.github/workflows/daily.yml
@@ -521,7 +521,7 @@ jobs:
repository: ${{ env.GITHUB_REPOSITORY }}
ref: ${{ env.GITHUB_HEAD_REF }}
- name: test
- uses: vmactions/freebsd-vm@v0.1.4
+ uses: vmactions/freebsd-vm@v0.1.5
with:
usesh: true
sync: rsync
diff --git a/.github/workflows/spell-check.yml b/.github/workflows/spell-check.yml
index 7aaa9ffa8..ac9cf2532 100644
--- a/.github/workflows/spell-check.yml
+++ b/.github/workflows/spell-check.yml
@@ -18,8 +18,15 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v2
+ - name: pip cache
+ uses: actions/cache@v2
+ with:
+ path: ~/.cache/pip
+ key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
+ restore-keys: ${{ runner.os }}-pip-
+
- name: Install prerequisites
- run: sudo pip install codespell==2.0.0
+ run: sudo pip install -r ./.codespell/requirements.txt
- name: Spell check
- run: codespell --config=./.github/.codespellrc
+ run: codespell --config=./.codespell/.codespellrc
diff --git a/src/db.c b/src/db.c
index fb08152e6..d2fa8aba9 100644
--- a/src/db.c
+++ b/src/db.c
@@ -69,7 +69,7 @@ void updateLFU(robj *val) {
* LOOKUP_NONE (or zero): No special flags are passed.
* LOOKUP_NOTOUCH: Don't alter the last access time of the key.
* LOOKUP_NONOTIFY: Don't trigger keyspace event on key miss.
- * LOOKUP_NOSTATS: Don't increment key hits/misses couters.
+ * LOOKUP_NOSTATS: Don't increment key hits/misses counters.
* LOOKUP_WRITE: Prepare the key for writing (delete expired keys even on
* replicas, use separate keyspace stats and events (TODO)).
*
diff --git a/src/module.c b/src/module.c
index 58e3bb666..dcc1641bf 100644
--- a/src/module.c
+++ b/src/module.c
@@ -7422,7 +7422,7 @@ RedisModuleString *RM_GetCurrentUserName(RedisModuleCtx *ctx) {
* Returns NULL if the user is disabled or the user does not exist.
* The caller should later free the user using the function RM_FreeModuleUser().*/
RedisModuleUser *RM_GetModuleUserFromUserName(RedisModuleString *name) {
- /* First, verfify that the user exist */
+ /* First, verify that the user exist */
user *acl_user = ACLGetUserByName(name->ptr, sdslen(name->ptr));
if (acl_user == NULL) {
return NULL;
diff --git a/src/replication.c b/src/replication.c
index 80dc33ad4..3bdd1cc89 100644
--- a/src/replication.c
+++ b/src/replication.c
@@ -329,7 +329,7 @@ void feedReplicationBuffer(char *s, size_t len) {
/* Install write handler for all replicas. */
prepareReplicasToWrite();
- size_t start_pos = 0; /* The position of referenced blok to start sending. */
+ size_t start_pos = 0; /* The position of referenced block to start sending. */
listNode *start_node = NULL; /* Replica/backlog starts referenced node. */
int add_new_block = 0; /* Create new block if current block is total used. */
listNode *ln = listLast(server.repl_buffer_blocks);
diff --git a/src/server.h b/src/server.h
index 5166f340a..959a8c645 100644
--- a/src/server.h
+++ b/src/server.h
@@ -2912,7 +2912,7 @@ int objectSetLRUOrLFU(robj *val, long long lfu_freq, long long lru_idle,
#define LOOKUP_NONE 0
#define LOOKUP_NOTOUCH (1<<0) /* Don't update LRU. */
#define LOOKUP_NONOTIFY (1<<1) /* Don't trigger keyspace event on key misses. */
-#define LOOKUP_NOSTATS (1<<2) /* Don't update keyspace hits/misses couters. */
+#define LOOKUP_NOSTATS (1<<2) /* Don't update keyspace hits/misses counters. */
#define LOOKUP_WRITE (1<<3) /* Delete expired keys even in replicas. */
void dbAdd(redisDb *db, robj *key, robj *val);