Skip to content

Commit 5d61ba3

Browse files
authored
[CI] Create .codespellrc; upgrade codespell hook; fix typos (#12824)
1 parent 5d95bdd commit 5d61ba3

File tree

7 files changed

+26
-8
lines changed

7 files changed

+26
-8
lines changed

.codespellrc

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
18+
[codespell]
19+
ignore-words = .github/linters/codespell.txt
20+
skip = systemvm/agent/noVNC/*,ui/package.json,ui/package-lock.json,ui/public/js/less.min.js,ui/public/locales/*.json,server/src/test/java/org/apache/cloudstack/network/ssl/CertServiceTest.java,test/integration/smoke/test_ssl_offloading.py

.pre-commit-config.yaml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -166,13 +166,11 @@ repos:
166166
args: [--markdown-linebreak-ext=md]
167167
exclude: ^services/console-proxy/rdpconsole/src/test/doc/freerdp-debug-log\.txt$
168168
- repo: https://github.com/codespell-project/codespell
169-
rev: v2.4.1
169+
rev: v2.4.2
170170
hooks:
171171
- id: codespell
172172
name: run codespell
173173
description: Check spelling with codespell
174-
args: [--ignore-words=.github/linters/codespell.txt]
175-
exclude: ^systemvm/agent/noVNC/|^ui/package\.json$|^ui/package-lock\.json$|^ui/public/js/less\.min\.js$|^ui/public/locales/.*[^n].*\.json$|^server/src/test/java/org/apache/cloudstack/network/ssl/CertServiceTest.java$|^test/integration/smoke/test_ssl_offloading.py$
176174
- repo: https://github.com/pycqa/flake8
177175
rev: 7.0.0
178176
hooks:

framework/db/src/main/java/com/cloud/utils/db/SequenceFetcher.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public <T> T getNextSequence(Class<T> clazz, TableGenerator tg, Object key, bool
6464
try {
6565
return future.get();
6666
} catch (Exception e) {
67-
logger.warn("Unable to get sequeunce for " + tg.table() + ":" + tg.pkColumnValue(), e);
67+
logger.warn("Unable to get sequence for " + tg.table() + ":" + tg.pkColumnValue(), e);
6868
return null;
6969
}
7070
}

test/integration/component/test_blocker_bugs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -542,7 +542,7 @@ def test_01_list_routers_admin(self):
542542

543543

544544
# Validate the following
545-
# 1. PreReq: have rounters that are owned by other account
545+
# 1. PreReq: have routers that are owned by other account
546546
# 2. Create domain and create accounts in that domain
547547
# 3. Create one VM for each account
548548
# 4. Using Admin , run listRouters. It should return all the routers

ui/docs/development.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ The following tree shows the basic UI codebase filesystem:
3232

3333
```bash
3434
src
35-
├── assests # sprites, icons, images
35+
├── assets # sprites, icons, images
3636
├── components # Shared vue files used to render various generic / widely used components
3737
├── config # Contains the layout details of the various routes / sections available in the UI
3838
├── locales # Custom translation keys for the various supported languages

utils/src/main/java/com/cloud/utils/nio/Link.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ public static SSLEngine initServerSSLEngine(final CAService caService, final Str
380380
if (caService != null) {
381381
return caService.createSSLEngine(sslContext, clientAddress);
382382
}
383-
LOGGER.error("CA service is not configured, by-passing CA manager to create SSL engine");
383+
LOGGER.error("CA service is not configured, bypassing CA manager to create SSL engine");
384384
char[] passphrase = KeyStoreUtils.DEFAULT_KS_PASSPHRASE;
385385
final KeyStore ks = loadKeyStore(NioConnection.class.getResourceAsStream("/cloud.keystore"), passphrase);
386386
final KeyManagerFactory kmf = KeyManagerFactory.getInstance("SunX509");

vmware-base/src/main/java/com/cloud/hypervisor/vmware/util/VmwareHelper.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -753,7 +753,7 @@ public static String getRecommendedDiskControllerFromDescriptor(GuestOsDescripto
753753

754754
recommendedController = guestOsDescriptor.getRecommendedDiskController();
755755

756-
// By-pass auto detected PVSCSI controller to use LsiLogic Parallel instead
756+
// Bypass auto detected PVSCSI controller to use LsiLogic Parallel instead
757757
if (DiskControllerType.getType(recommendedController) == DiskControllerType.pvscsi) {
758758
recommendedController = DiskControllerType.lsilogic.toString();
759759
}

0 commit comments

Comments
 (0)