aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorMiquel Sabaté Solà <msabate@suse.com>2019-09-05 14:00:25 +0200
committerMiquel Sabaté Solà <msabate@suse.com>2019-09-05 16:46:12 +0200
commit99f78178964d12e3a8ae6cc4aebf894320e562df (patch)
tree1c780d0b9d4740a41616ae716decbc469a102d8d /bin
parent0f3444ced75558884334a99fc04b9c72b1924e42 (diff)
downloaddotfiles-99f78178964d12e3a8ae6cc4aebf894320e562df.tar.gz
dotfiles-99f78178964d12e3a8ae6cc4aebf894320e562df.zip
Added linters and polished code
The minimum version supported has been raised to 25.3. Signed-off-by: Miquel Sabaté Solà <msabate@suse.com>
Diffstat (limited to 'bin')
-rwxr-xr-xbin/json2yaml.rb1
-rwxr-xr-xbin/test/test.sh4
2 files changed, 3 insertions, 2 deletions
diff --git a/bin/json2yaml.rb b/bin/json2yaml.rb
index 4f77f8b..6239e8a 100755
--- a/bin/json2yaml.rb
+++ b/bin/json2yaml.rb
@@ -1,4 +1,5 @@
#!/usr/bin/env ruby
+# frozen_string_literal: true
require 'json'
require 'yaml'
diff --git a/bin/test/test.sh b/bin/test/test.sh
index 666818a..20f9439 100755
--- a/bin/test/test.sh
+++ b/bin/test/test.sh
@@ -26,7 +26,7 @@ status=0
# license main.cpp
$license "$dir/main.cpp"
d=$(diff "$dir/main.cpp" "$dir/main.cpp.expected")
-if [ ! -z "$d" ]; then
+if [ -n "$d" ]; then
echo "$d"
status=1
fi
@@ -34,7 +34,7 @@ fi
# license README.md
$license "$dir/README.md"
d=$(diff "$dir/README.md" "$dir/README.md.expected")
-if [ ! -z "$d" ]; then
+if [ -n "$d" ]; then
echo "$d"
status=1
fi