na 1.2.4 → 1.2.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/Gemfile.lock +1 -1
- data/README.md +2 -2
- data/lib/na/next_action.rb +6 -3
- data/lib/na/version.rb +1 -1
- data/src/README.md +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 145c2efb28f23a047dced5bad341aa9339ff437fd4f31faeb44923fdc5d6af0c
|
4
|
+
data.tar.gz: b16951edb2e2753c8c1a83a52b1650db7770a4d6ac2615aa4995e37bdcf20a02
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e790052ffdabf6ee749f545d4dade110a45167174700fc3f351d4e688b870c8b7bebf063678232613c12d1e3db3f0bc4491f12a01eededd0c8fd0d8710cfc63c
|
7
|
+
data.tar.gz: c433b14e48f7ee09ca8a3a27a305b67e21087e0230a16d6f75c1b9d404e46ee5f120a8411f1f1d139b6e36512ac866ad5edc0ca2f29530b7b990baf0da776b16
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -9,7 +9,7 @@
|
|
9
9
|
_If you're one of the rare people like me who find this useful, feel free to
|
10
10
|
[buy me some coffee][donate]._
|
11
11
|
|
12
|
-
The current version of `na` is 1.2.
|
12
|
+
The current version of `na` is 1.2.5
|
13
13
|
.
|
14
14
|
|
15
15
|
`na` ("next action") is a command line tool designed to make it easy to see what your next actions are for any project, right from the command line. It works with TaskPaper-formatted files (but any plain text format will do), looking for `@na` tags (or whatever you specify) in todo files in your current folder.
|
@@ -63,7 +63,7 @@ SYNOPSIS
|
|
63
63
|
na [global options] command [command options] [arguments...]
|
64
64
|
|
65
65
|
VERSION
|
66
|
-
1.2.
|
66
|
+
1.2.5
|
67
67
|
|
68
68
|
GLOBAL OPTIONS
|
69
69
|
-a, --[no-]add - Add a next action (deprecated, for backwards compatibility)
|
data/lib/na/next_action.rb
CHANGED
@@ -316,6 +316,7 @@ module NA
|
|
316
316
|
contents = target.read_file.split(/\n/)
|
317
317
|
|
318
318
|
if add.is_a?(Action)
|
319
|
+
add_tag ||= []
|
319
320
|
action = process_action(add, priority: priority, finish: finish, add_tag: add_tag, remove_tag: remove_tag)
|
320
321
|
|
321
322
|
projects = find_projects(target)
|
@@ -397,6 +398,7 @@ module NA
|
|
397
398
|
contents.insert(target_line, "#{indent}\t- #{action.action}#{note}")
|
398
399
|
end
|
399
400
|
end
|
401
|
+
|
400
402
|
backup_file(target)
|
401
403
|
File.open(target, 'w') { |f| f.puts contents.join("\n") }
|
402
404
|
|
@@ -751,9 +753,10 @@ module NA
|
|
751
753
|
## @param target [String] The file to back up
|
752
754
|
##
|
753
755
|
def backup_file(target)
|
754
|
-
|
755
|
-
|
756
|
-
FileUtils.cp(target,
|
756
|
+
file = ".#{File.basename(target)}.bak"
|
757
|
+
backup = File.join(File.dirname(target), file)
|
758
|
+
FileUtils.cp(target, backup)
|
759
|
+
NA.notify("{dw}Backup file created at #{backup}", debug: true)
|
757
760
|
end
|
758
761
|
|
759
762
|
##
|
data/lib/na/version.rb
CHANGED
data/src/README.md
CHANGED
@@ -9,7 +9,7 @@
|
|
9
9
|
_If you're one of the rare people like me who find this useful, feel free to
|
10
10
|
[buy me some coffee][donate]._
|
11
11
|
|
12
|
-
The current version of `na` is <!--VER-->1.2.
|
12
|
+
The current version of `na` is <!--VER-->1.2.4<!--END VER-->.
|
13
13
|
|
14
14
|
`na` ("next action") is a command line tool designed to make it easy to see what your next actions are for any project, right from the command line. It works with TaskPaper-formatted files (but any plain text format will do), looking for `@na` tags (or whatever you specify) in todo files in your current folder.
|
15
15
|
|