chore: integrate codespell and fix existing spelling issues

This tool scans the comments of every source file and reports back
spelling errors.

Signed-off-by: Juan Cruz Viotti <jviotti@openmailbox.org>
This commit is contained in:
Juan Cruz Viotti 2017-01-31 10:07:29 -04:00
parent 95d4f2f608
commit 8e5840ce69
12 changed files with 26 additions and 7 deletions

View File

@ -37,6 +37,7 @@ before_install:
install: install:
- if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
pip install codespell;
gem install scss_lint; gem install scss_lint;
npm install -g bower electron-installer-debian; npm install -g bower electron-installer-debian;
npm install -g electron-installer-debian; npm install -g electron-installer-debian;

View File

@ -34,6 +34,7 @@ install:
- set PATH=C:\MinGW\bin;%PATH% - set PATH=C:\MinGW\bin;%PATH%
- set PATH=C:\MinGW\msys\1.0\bin;%PATH% - set PATH=C:\MinGW\msys\1.0\bin;%PATH%
- gem install scss_lint - gem install scss_lint
- pip install codespell
- make info - make info
- make electron-develop - make electron-develop

View File

@ -16,6 +16,7 @@ Prerequisites
- [SCSS Lint](https://github.com/brigade/scss-lint/) - [SCSS Lint](https://github.com/brigade/scss-lint/)
- [jq](https://stedolan.github.io/jq/) - [jq](https://stedolan.github.io/jq/)
- [Asar](https://github.com/electron/asar) - [Asar](https://github.com/electron/asar)
- [Codespell](https://github.com/lucasdemarchi/codespell)
### Windows ### Windows

View File

@ -23,7 +23,7 @@
<!-- There can be a case where the device it not large enough, and it's also locked. --> <!-- There can be a case where the device it not large enough, and it's also locked. -->
<!-- Since in this case both labels will be displayed, we chose to only show the --> <!-- Since in this case both labels will be displayed, we chose to only show the -->
<!-- "not large enough label", since from the point of view of the user, the locked --> <!-- "not large enough label", since from the point of view of the user, the locked -->
<!-- state is irrelevent if the drive is not large enough anyway. --> <!-- state is irrelevant if the drive is not large enough anyway. -->
<span class="label label-danger" <span class="label label-danger"
ng-hide="modal.constraints.isDriveLargeEnough(drive, modal.state.getImage())"> ng-hide="modal.constraints.isDriveLargeEnough(drive, modal.state.getImage())">

View File

@ -26,7 +26,7 @@ body {
background-color: $palette-theme-dark-background; background-color: $palette-theme-dark-background;
} }
// Fix slighly checkbox vertical alignment issue // Fix slight checkbox vertical alignment issue
.checkbox input[type="checkbox"] { .checkbox input[type="checkbox"] {
position: initial; position: initial;
margin-right: 2px; margin-right: 2px;

View File

@ -85,7 +85,7 @@ exports.getFromFilePath = (file) => {
* @description * @description
* This function is useful to determine the final size of an image * This function is useful to determine the final size of an image
* after decompression or any other needed transformation, as well as * after decompression or any other needed transformation, as well as
* other relevent metadata, if any. * other relevant metadata, if any.
* *
* **NOTE:** This function is known to output incorrect size results for * **NOTE:** This function is known to output incorrect size results for
* `bzip2`. For this compression format, this function will simply * `bzip2`. For this compression format, this function will simply

View File

@ -15,7 +15,8 @@
"sass": "node-sass ./lib/gui/scss/main.scss > ./lib/gui/css/main.css", "sass": "node-sass ./lib/gui/scss/main.scss > ./lib/gui/css/main.css",
"jslint": "eslint lib tests scripts bin versionist.conf.js", "jslint": "eslint lib tests scripts bin versionist.conf.js",
"scsslint": "scss-lint lib/gui/scss", "scsslint": "scss-lint lib/gui/scss",
"lint": "npm run jslint && npm run scsslint", "codespell": "codespell.py lib tests",
"lint": "npm run jslint && npm run scsslint && npm run codespell",
"changelog": "versionist", "changelog": "versionist",
"start": "electron lib/start.js", "start": "electron lib/start.js",
"clean-shrinkwrap": "node ./scripts/clean-shrinkwrap.js" "clean-shrinkwrap": "node ./scripts/clean-shrinkwrap.js"

View File

@ -14,6 +14,8 @@ RUN apt-get update && apt-get install -y \
libxss1 \ libxss1 \
libxtst6 \ libxtst6 \
python \ python \
python-pip \
python-dev \
python-software-properties \ python-software-properties \
software-properties-common \ software-properties-common \
upx \ upx \
@ -28,6 +30,9 @@ RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - \
RUN npm config set spin=false RUN npm config set spin=false
RUN npm install -g bower asar electron-installer-debian RUN npm install -g bower asar electron-installer-debian
# Python
RUN pip install codespell
# Ruby # Ruby
RUN add-apt-repository ppa:brightbox/ruby-ng RUN add-apt-repository ppa:brightbox/ruby-ng
RUN apt-get update RUN apt-get update

View File

@ -14,6 +14,8 @@ RUN apt-get update && apt-get install -y \
libxss1 \ libxss1 \
libxtst6 \ libxtst6 \
python \ python \
python-pip \
python-dev \
python-software-properties \ python-software-properties \
software-properties-common \ software-properties-common \
upx \ upx \
@ -28,6 +30,9 @@ RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - \
RUN npm config set spin=false RUN npm config set spin=false
RUN npm install -g bower asar electron-installer-debian RUN npm install -g bower asar electron-installer-debian
# Python
RUN pip install codespell
# Ruby # Ruby
RUN add-apt-repository ppa:brightbox/ruby-ng RUN add-apt-repository ppa:brightbox/ruby-ng
RUN apt-get update RUN apt-get update

View File

@ -14,6 +14,8 @@ RUN apt-get update && apt-get install -y \
libxss1 \ libxss1 \
libxtst6 \ libxtst6 \
python \ python \
python-pip \
python-dev \
python-software-properties \ python-software-properties \
software-properties-common \ software-properties-common \
upx \ upx \
@ -28,6 +30,9 @@ RUN curl -sL https://deb.nodesource.com/setup_6.x | bash - \
RUN npm config set spin=false RUN npm config set spin=false
RUN npm install -g bower asar electron-installer-debian RUN npm install -g bower asar electron-installer-debian
# Python
RUN pip install codespell
# Ruby # Ruby
RUN add-apt-repository ppa:brightbox/ruby-ng RUN add-apt-repository ppa:brightbox/ruby-ng
RUN apt-get update RUN apt-get update

View File

@ -30,7 +30,7 @@ describe('Browser: ImageWriter', function() {
describe('.flash()', function() { describe('.flash()', function() {
describe('given a succesful write', function() { describe('given a successful write', function() {
beforeEach(function() { beforeEach(function() {
this.performWriteStub = m.sinon.stub(ImageWriterService, 'performWrite'); this.performWriteStub = m.sinon.stub(ImageWriterService, 'performWrite');
@ -83,7 +83,7 @@ describe('Browser: ImageWriter', function() {
}); });
describe('given an unsuccesful write', function() { describe('given an unsuccessful write', function() {
beforeEach(function() { beforeEach(function() {
this.performWriteStub = m.sinon.stub(ImageWriterService, 'performWrite'); this.performWriteStub = m.sinon.stub(ImageWriterService, 'performWrite');