peter-notes 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +16 -0
- data/.rspec +2 -0
- data/.travis.yml +5 -0
- data/CODE_OF_CONDUCT.md +74 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +101 -0
- data/Rakefile +6 -0
- data/bin/console +9 -0
- data/bin/notes +4 -0
- data/bin/ronn +2 -0
- data/bin/setup +7 -0
- data/bin/test +2 -0
- data/lib/models/console_app.rb +28 -0
- data/lib/models/notes.rb +59 -0
- data/lib/models/preferences.rb +52 -0
- data/lib/peter_notes/peter_notes.rb +9 -0
- data/lib/peter_notes/version.rb +3 -0
- data/man/peter-notes.7 +134 -0
- data/man/peter-notes.7.html +181 -0
- data/man/peter-notes.7.ronn +98 -0
- data/peter-notes.gemspec +30 -0
- metadata +153 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 8567079aac32d75f712b96488dc8303f70d6cac5
|
4
|
+
data.tar.gz: 7c3e03bd57b2153f2b0276426a08c4ceb8ac7db7
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 8fbb5fb4259d4343699179c800120ca1a667dabf45f8ace5dcd02275f6763776301f953376511313b4d42b20ab44c8930103aa1d5cf9a6550535890c633f02dd
|
7
|
+
data.tar.gz: aeef8aa50829d6861ca3c8c3439502740934c013d8ecb72d8c878021c36b8284bbf9f6c74b4d18f480c9b3b70edae132e04773d6f40a0259652efa7d0f035061
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,74 @@
|
|
1
|
+
# Contributor Covenant Code of Conduct
|
2
|
+
|
3
|
+
## Our Pledge
|
4
|
+
|
5
|
+
In the interest of fostering an open and welcoming environment, we as
|
6
|
+
contributors and maintainers pledge to making participation in our project and
|
7
|
+
our community a harassment-free experience for everyone, regardless of age, body
|
8
|
+
size, disability, ethnicity, gender identity and expression, level of experience,
|
9
|
+
nationality, personal appearance, race, religion, or sexual identity and
|
10
|
+
orientation.
|
11
|
+
|
12
|
+
## Our Standards
|
13
|
+
|
14
|
+
Examples of behavior that contributes to creating a positive environment
|
15
|
+
include:
|
16
|
+
|
17
|
+
* Using welcoming and inclusive language
|
18
|
+
* Being respectful of differing viewpoints and experiences
|
19
|
+
* Gracefully accepting constructive criticism
|
20
|
+
* Focusing on what is best for the community
|
21
|
+
* Showing empathy towards other community members
|
22
|
+
|
23
|
+
Examples of unacceptable behavior by participants include:
|
24
|
+
|
25
|
+
* The use of sexualized language or imagery and unwelcome sexual attention or
|
26
|
+
advances
|
27
|
+
* Trolling, insulting/derogatory comments, and personal or political attacks
|
28
|
+
* Public or private harassment
|
29
|
+
* Publishing others' private information, such as a physical or electronic
|
30
|
+
address, without explicit permission
|
31
|
+
* Other conduct which could reasonably be considered inappropriate in a
|
32
|
+
professional setting
|
33
|
+
|
34
|
+
## Our Responsibilities
|
35
|
+
|
36
|
+
Project maintainers are responsible for clarifying the standards of acceptable
|
37
|
+
behavior and are expected to take appropriate and fair corrective action in
|
38
|
+
response to any instances of unacceptable behavior.
|
39
|
+
|
40
|
+
Project maintainers have the right and responsibility to remove, edit, or
|
41
|
+
reject comments, commits, code, wiki edits, issues, and other contributions
|
42
|
+
that are not aligned to this Code of Conduct, or to ban temporarily or
|
43
|
+
permanently any contributor for other behaviors that they deem inappropriate,
|
44
|
+
threatening, offensive, or harmful.
|
45
|
+
|
46
|
+
## Scope
|
47
|
+
|
48
|
+
This Code of Conduct applies both within project spaces and in public spaces
|
49
|
+
when an individual is representing the project or its community. Examples of
|
50
|
+
representing a project or community include using an official project e-mail
|
51
|
+
address, posting via an official social media account, or acting as an appointed
|
52
|
+
representative at an online or offline event. Representation of a project may be
|
53
|
+
further defined and clarified by project maintainers.
|
54
|
+
|
55
|
+
## Enforcement
|
56
|
+
|
57
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be
|
58
|
+
reported by contacting the project team at peter.nfonseca@gmail.com. All
|
59
|
+
complaints will be reviewed and investigated and will result in a response that
|
60
|
+
is deemed necessary and appropriate to the circumstances. The project team is
|
61
|
+
obligated to maintain confidentiality with regard to the reporter of an incident.
|
62
|
+
Further details of specific enforcement policies may be posted separately.
|
63
|
+
|
64
|
+
Project maintainers who do not follow or enforce the Code of Conduct in good
|
65
|
+
faith may face temporary or permanent repercussions as determined by other
|
66
|
+
members of the project's leadership.
|
67
|
+
|
68
|
+
## Attribution
|
69
|
+
|
70
|
+
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
|
71
|
+
available at [http://contributor-covenant.org/version/1/4][version]
|
72
|
+
|
73
|
+
[homepage]: http://contributor-covenant.org
|
74
|
+
[version]: http://contributor-covenant.org/version/1/4/
|
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2017 Peter Fonseca
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,101 @@
|
|
1
|
+
# Peter Notes
|
2
|
+
|
3
|
+
Manage your notes from the console.
|
4
|
+
|
5
|
+
If you're like me, you spend most of your computing time in a terminal. You have a text-editor that's heavily customized to your liking, and you wish you could read and write everything with it. Naturally, you feel the same about your notes and, when it comes time to ditch the note-pad, you refuse to to use the more popular gui-driven apps.
|
6
|
+
|
7
|
+
But when you start looking for a console-based notes framework you're blinded by crazy features and unwilling to learn a new tool. You've also already started keeping some text files in a directory and just cd into them all the time. Eventually you write an alias and call it a day.
|
8
|
+
|
9
|
+
That's what I did. I also turned my alias into a bash function and wrote a couple more after I got tired of grepping on my own. At a certain point I got tired of writing bash and migrated to a ruby project. It was probably way more work than learning a new tool but I think it's pretty cool so whatever.
|
10
|
+
|
11
|
+
Anyway, I made this this lightweight tool to do what I wanted it to do, which isn't a lot. It's essentially `cd`, `grep`, `tree`, and `find` wrapped into some nicer syntax with a preferences file to hold the info that you don't want to keep typing. That means it'll stay out of the way and let you choose where you keep your notes, how you organize them, how you track them (if you do), and what editor you use to write them. You can even just point it at your notes and stop cding and grepping into them manually.
|
12
|
+
|
13
|
+
I made it for myself, and mostly packaged it into a ruby gem so I could keep it on all my computers/virtual machines, but if anyone else out there ever uses this, hopefully you like it. Much like Mr. Matsumoto, I think programming should be simple and linguistic, and I feel the same about the console.
|
14
|
+
|
15
|
+
## Installation
|
16
|
+
|
17
|
+
$ gem install peter-notes
|
18
|
+
|
19
|
+
## Usage
|
20
|
+
|
21
|
+
`notes`. Yeah.
|
22
|
+
|
23
|
+
But you can do more!
|
24
|
+
|
25
|
+
Lets assume you have the following notes:
|
26
|
+
|
27
|
+
/Users/peter/Notes/
|
28
|
+
|-- projects
|
29
|
+
| |-- python
|
30
|
+
| | +-- jarbs.txt
|
31
|
+
| +-- ruby
|
32
|
+
| +-- peter_notes.txt
|
33
|
+
+-- other
|
34
|
+
+-- motorcycle.txt
|
35
|
+
|
36
|
+
Most of the time you just want to open them. To do that, just type `notes`. You can specify your text editor and where your notes are in `~/peter-notes.yaml` (see the preferences section below).
|
37
|
+
|
38
|
+
If you want to open a specific note, you can pass in a `file-glob` to specify which notes you want to open. If you think a file glob is what happens when you spill coffee on your computer, just check this out [this](http://tldp.org/LDP/abs/html/globbingref.html) or google it (hint, you use it in bash a lot, like, when you `ls *.rb`).
|
39
|
+
|
40
|
+
If you just want to open `other/motorcycle.txt` you can run `notes "other/motorcycle.txt"`. But that's kind of lame, so you could also fo `notes "motorcycle.txt"`, or even `notes "moto*"`. If you're feeling extra crazy, you could even get away with `m*` in this case, basically if you pass a glob in, `peter-notes` will just take the first match in `--find` (see below) and open that.
|
41
|
+
|
42
|
+
If you wanted to open all notes under `projects/` you could also use this same idea and run `notes "projects"`.
|
43
|
+
|
44
|
+
That's like what 90% of what you'll ever need and no crazy macros or flags to memorize. Not bad right? Well not all flags are bad, in fact, you also get some super-helpful optional ones for the other 10%:
|
45
|
+
|
46
|
+
- `-s`, `--search REGEX`:
|
47
|
+
Search within notes for text matching the specified `REGEX`. If you haven't guessed, this is the [grep](http://linuxcommand.org/man_pages/grep1.html) part. Specifically, it's running `grep -r YOUR-NOTES-DIR -e REGEX`.
|
48
|
+
|
49
|
+
- `-f`, `--find FILE-GLOB`:
|
50
|
+
Seach for notes that match the specified file-glob. This one's running [find](http://linuxcommand.org/man_pages/find1.html) -- `find YOUR-NOTES-DIR -name FILE-GLOB`. It's a little more than that though, this will be fuzzy in that you can add some path info to your glob. For example, if you ran `notes --find "projects/*.txt"`, you'd get back both `projects/python/jarbs.txt` and `projects/ruby/peter_notes.txt`. So it's better than just find. A little.
|
51
|
+
|
52
|
+
- `-l`, `--list [PATH]`:
|
53
|
+
List all notes or, if a `PATH` is specified, list notes within the specified path. Bet you thought this was running `ls -r`, well it's actually running [tree](http://linuxcommand.org/man_pages/tree1.html) because it's much cooler -- `tree YOUR-NOTES-DIR/PATH`.
|
54
|
+
|
55
|
+
Oh yeah, make sure your terminal has `grep`, `find`, and `tree`. It should, but depends on how crazy your 'gear' is. Also, this is a cli tool, don't try to import it into some ruby source code.
|
56
|
+
|
57
|
+
## Preferences
|
58
|
+
|
59
|
+
Preferences are saved in `~/.peter-notes.yml`. There are just 2 options that you can set so don't freak out:
|
60
|
+
|
61
|
+
- `editor`:
|
62
|
+
The editor of your choice. This value will get passed to bash so make sure you use the exact name your terminal will understand.
|
63
|
+
|
64
|
+
**Possible Values**: `[vim, subl, atom, emacs, nano]`
|
65
|
+
(more?) I haven't tested others and dont know which work well when opening a directory. For vim I use the NerdTree plugin.
|
66
|
+
|
67
|
+
**Default Value**: `vim`
|
68
|
+
|
69
|
+
- `notes_dir`:
|
70
|
+
The home of your notes. This is where `notes` will look for them.
|
71
|
+
|
72
|
+
**Possible Values**: any valid + existing dorectory path. I use `~/GoogleDrive/Notes` because I track mine in google drive (OverGrive for linux).
|
73
|
+
|
74
|
+
**Default Value**: `~/Notes`
|
75
|
+
|
76
|
+
That's [yaml](http://www.yaml.org/start.html) so it should look like this:
|
77
|
+
|
78
|
+
```yaml
|
79
|
+
editor: vim
|
80
|
+
notes_dir: /home/peter/Notes
|
81
|
+
```
|
82
|
+
|
83
|
+
## Development
|
84
|
+
|
85
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `bin/test` to run the tests. You can also run `bin/console` for an interactive [pry](http://pryrepl.org/) prompt.
|
86
|
+
|
87
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
88
|
+
|
89
|
+
If you're changing the man page, generate roff and html files with `bin/ronn`.
|
90
|
+
|
91
|
+
## Contributing
|
92
|
+
|
93
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/fonsecapeter/peter-notes. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](http://contributor-covenant.org) code of conduct.
|
94
|
+
|
95
|
+
## License
|
96
|
+
|
97
|
+
The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
|
98
|
+
|
99
|
+
## Code of Conduct
|
100
|
+
|
101
|
+
Everyone interacting in the peter-notes project’s codebases, issue trackers, chat rooms and mailing lists is expected to follow the [code of conduct](https://github.com/fonsecapeter/peter-notes/blob/master/CODE_OF_CONDUCT.md).
|
data/Rakefile
ADDED
data/bin/console
ADDED
data/bin/notes
ADDED
data/bin/ronn
ADDED
data/bin/setup
ADDED
data/bin/test
ADDED
@@ -0,0 +1,28 @@
|
|
1
|
+
require 'optparse'
|
2
|
+
|
3
|
+
class ConsoleApp
|
4
|
+
def run
|
5
|
+
OptionParser.new do |opts|
|
6
|
+
opts.banner = 'Usage: notes [options]'
|
7
|
+
opts.separator('')
|
8
|
+
opts.separator('Options:')
|
9
|
+
opts.separator(' [FILE-GLOB] Open the first file that matches FILE-GLOB if supplied')
|
10
|
+
opts.on('-s', '--search REGEX', 'Search within notes') do |regex|
|
11
|
+
self.search(regex)
|
12
|
+
exit(0)
|
13
|
+
end
|
14
|
+
opts.on('-f', '--find FILE-GLOB', 'Find notes that match FILE-GLOB') do |glob|
|
15
|
+
puts(self.find(glob))
|
16
|
+
exit(0)
|
17
|
+
end
|
18
|
+
opts.on('-l', '--list [PATH]', 'List all notes', ' (list notes under PATH if supplied)') do |path|
|
19
|
+
puts(self.list(path))
|
20
|
+
exit(0)
|
21
|
+
end
|
22
|
+
opts.on('-h', '--help', 'Show this message') do
|
23
|
+
puts(opts)
|
24
|
+
exit(0)
|
25
|
+
end
|
26
|
+
end.parse!
|
27
|
+
end
|
28
|
+
end
|
data/lib/models/notes.rb
ADDED
@@ -0,0 +1,59 @@
|
|
1
|
+
require_relative 'console_app'
|
2
|
+
require_relative 'preferences'
|
3
|
+
|
4
|
+
class Notes < ConsoleApp
|
5
|
+
attr_reader :editor, :notes_dir
|
6
|
+
|
7
|
+
def initialize(prefs)
|
8
|
+
@editor = prefs.editor
|
9
|
+
@notes_dir = prefs.notes_dir
|
10
|
+
end
|
11
|
+
|
12
|
+
def search(regex)
|
13
|
+
system("grep --color=always -r #{@notes_dir} -e #{regex}")
|
14
|
+
end
|
15
|
+
|
16
|
+
def find(glob)
|
17
|
+
parsed = glob.split('/')
|
18
|
+
glob_terminus = parsed.pop
|
19
|
+
glob_path = parsed.join('/')
|
20
|
+
cmd = "find \"#{@notes_dir}\" -name \"#{glob_terminus}\""
|
21
|
+
if glob_path != ''
|
22
|
+
cmd += " | grep \"#{glob_path}\""
|
23
|
+
end
|
24
|
+
found = `#{cmd}`
|
25
|
+
return found.split
|
26
|
+
end
|
27
|
+
|
28
|
+
def open_notes(glob=nil)
|
29
|
+
enter_dir
|
30
|
+
found = find(glob)[0]
|
31
|
+
if found.nil?
|
32
|
+
found = './'
|
33
|
+
end
|
34
|
+
system("#{@editor} #{found}")
|
35
|
+
leave_dir
|
36
|
+
end
|
37
|
+
|
38
|
+
def list(path)
|
39
|
+
system("tree #{@notes_dir}/#{path}")
|
40
|
+
end
|
41
|
+
|
42
|
+
def run
|
43
|
+
super
|
44
|
+
glob = ARGV[0]
|
45
|
+
open_notes(glob)
|
46
|
+
end
|
47
|
+
|
48
|
+
private
|
49
|
+
|
50
|
+
def enter_dir
|
51
|
+
@cur_dir = Dir.pwd
|
52
|
+
Dir.chdir(@notes_dir)
|
53
|
+
end
|
54
|
+
|
55
|
+
def leave_dir
|
56
|
+
Dir.chdir(@cur_dir)
|
57
|
+
end
|
58
|
+
|
59
|
+
end
|
@@ -0,0 +1,52 @@
|
|
1
|
+
require 'yaml'
|
2
|
+
|
3
|
+
class Preferences
|
4
|
+
attr_reader :editor, :notes_dir, :preferences
|
5
|
+
|
6
|
+
@@home_dir = ENV['HOME']
|
7
|
+
@@defaults = {
|
8
|
+
editor: 'vim',
|
9
|
+
notes_dir: "#{@@home_dir}/Notes"
|
10
|
+
}
|
11
|
+
@@prefs_file = "#{@@home_dir}/.peter-notes.yml"
|
12
|
+
|
13
|
+
def self.defaults
|
14
|
+
@@defaults
|
15
|
+
end
|
16
|
+
|
17
|
+
def self.prefs_file
|
18
|
+
@@prefs_file
|
19
|
+
end
|
20
|
+
|
21
|
+
def initialize(prefs=nil)
|
22
|
+
@preferences = prefs || load_preferences
|
23
|
+
@preferences[:notes_dir] = File.expand_path(@preferences[:notes_dir])
|
24
|
+
@editor = @preferences[:editor]
|
25
|
+
@notes_dir = @preferences[:notes_dir]
|
26
|
+
end
|
27
|
+
|
28
|
+
def self.write_yaml_defaults
|
29
|
+
File.write(@@prefs_file, @@defaults.to_yaml)
|
30
|
+
end
|
31
|
+
|
32
|
+
private
|
33
|
+
|
34
|
+
def load_yaml_preferences
|
35
|
+
prefs = YAML::load_file(@@prefs_file)
|
36
|
+
return(
|
37
|
+
prefs.inject({}) do |processed, (key, val)|
|
38
|
+
processed[key.to_sym] = val
|
39
|
+
processed
|
40
|
+
end
|
41
|
+
)
|
42
|
+
end
|
43
|
+
|
44
|
+
def load_preferences
|
45
|
+
if File.exists?(@@prefs_file)
|
46
|
+
prefs = load_yaml_preferences
|
47
|
+
return(@@defaults.merge(prefs))
|
48
|
+
else
|
49
|
+
return @@defaults
|
50
|
+
end
|
51
|
+
end
|
52
|
+
end
|
data/man/peter-notes.7
ADDED
@@ -0,0 +1,134 @@
|
|
1
|
+
.\" generated with Ronn/v0.7.3
|
2
|
+
.\" http://github.com/rtomayko/ronn/tree/0.7.3
|
3
|
+
.
|
4
|
+
.TH "PETER\-NOTES" "1" "June 2017" "" ""
|
5
|
+
.
|
6
|
+
.SH "NAME"
|
7
|
+
\fBpeter\-notes\fR \- manage your notes from the terminal
|
8
|
+
.
|
9
|
+
.SH "SYNOPSIS"
|
10
|
+
\fBnotes\fR [\fIFILE\-GLOB\fR]
|
11
|
+
.
|
12
|
+
.br
|
13
|
+
\fBnotes\fR \fB\-s\fR|\fB\-\-search\fR \fIREGEX\fR
|
14
|
+
.
|
15
|
+
.br
|
16
|
+
\fBnotes\fR \fB\-f\fR|\fB\-\-find\fR \fIFILE\-GLOB\fR
|
17
|
+
.
|
18
|
+
.br
|
19
|
+
\fBnotes\fR \fB\-l\fR|\fB\-\-list\fR [\fIPATH\fR]
|
20
|
+
.
|
21
|
+
.br
|
22
|
+
.
|
23
|
+
.SH "DESCRIPTION"
|
24
|
+
This document describes the \fBpeter\-notes\fR tool\. This simple ruby gem is an awesome way to manage personal notes from the terminal\.
|
25
|
+
.
|
26
|
+
.SH "OPTIONS"
|
27
|
+
These options provide some extra utility beyond simply opening notes for editing\.
|
28
|
+
.
|
29
|
+
.TP
|
30
|
+
\fB\-s\fR, \fB\-\-search <REGEX>\fR
|
31
|
+
Search within notes for text matching the specified \fBREGEX\fR\. If you havent guessed, this is the grep \fIhttp://linuxcommand\.org/man_pages/grep1\.html\fR part\. Specifically, its running \fBgrep \-r YOUR\-NOTES\-DIR \-e REGEX\fR\.
|
32
|
+
.
|
33
|
+
.TP
|
34
|
+
\fB\-f\fR, \fB\-\-find <FILE\-GLOB>\fR
|
35
|
+
Seach for notes that match the specified file\-glob\. This ones running find \fIhttp://linuxcommand\.org/man_pages/find1\.html\fR \-\- \fBfind YOUR\-NOTES\-DIR \-name FILE\-GLOB\fR\. Its a little more than that though, this will be fuzzy in that you can add some path info to your glob\. For example, if you ran \fBnotes \-\-find "projects/*\.txt"\fR, youd get back both \fBprojects/python/jarbs\.txt\fR and \fBprojects/ruby/peter_notes\.txt\fR\. So its better than just find\. A little\.
|
36
|
+
.
|
37
|
+
.TP
|
38
|
+
\fB\-l\fR, \fB\-\-list [<PATH>]\fR
|
39
|
+
List all notes or, if a \fBPATH\fR is specified, list notes within the specified path\. Bet you thought this was running \fBls \-r\fR, well its actually running tree \fIhttp://linuxcommand\.org/man_pages/tree1\.html\fR because its much cooler \-\- \fBtree YOUR\-NOTES\-DIR/PATH\fR\.
|
40
|
+
.
|
41
|
+
.SH "EXAMPLES"
|
42
|
+
\fBnotes\fR\. Yeah\.
|
43
|
+
.
|
44
|
+
.P
|
45
|
+
But you can do more!
|
46
|
+
.
|
47
|
+
.P
|
48
|
+
Lets assume you have the following notes:
|
49
|
+
.
|
50
|
+
.IP "" 4
|
51
|
+
.
|
52
|
+
.nf
|
53
|
+
|
54
|
+
/Users/peter/Notes/
|
55
|
+
|\-\- projects
|
56
|
+
| |\-\- python
|
57
|
+
| | +\-\- jarbs\.txt
|
58
|
+
| +\-\- ruby
|
59
|
+
| +\-\- peter_notes\.txt
|
60
|
+
+\-\- other
|
61
|
+
+\-\- motorcycle\.txt
|
62
|
+
.
|
63
|
+
.fi
|
64
|
+
.
|
65
|
+
.IP "" 0
|
66
|
+
.
|
67
|
+
.P
|
68
|
+
Most of the time you just want to open them\. To do that, just type \fBnotes\fR\. You can specify your text editor and where your notes are in \fB~/peter\-notes\.yaml\fR (see the preferences section below)\.
|
69
|
+
.
|
70
|
+
.P
|
71
|
+
If you want to open a specific note, you can pass in a \fBfile\-glob\fR to specify which notes you want to open\. If you think a file glob is what happens when you spill coffee on your computer, just check this out this \fIhttp://tldp\.org/LDP/abs/html/globbingref\.html\fR or google it (hint, you use it in bash a lot, like, when you \fBls *\.rb\fR)\.
|
72
|
+
.
|
73
|
+
.P
|
74
|
+
If you just want to open \fBother/motorcycle\.txt\fR you can run \fBnotes "other/motorcycle\.txt"\fR\. But thats kind of lame, so you could also fo \fBnotes "motorcycle\.txt"\fR, or even \fBnotes "moto*"\fR\. If youre feeling extra crazy, you could even get away with \fBm*\fR in this case, basically if you pass a glob in, \fBpeter\-notes\fR will just take the first match in \fB\-\-find\fR (see below) and open that\.
|
75
|
+
.
|
76
|
+
.P
|
77
|
+
If you wanted to open all notes under \fBprojects/\fR you could also use this same idea and run \fBnotes "projects"\fR\.
|
78
|
+
.
|
79
|
+
.P
|
80
|
+
Thats like what 90% of what youll ever need and no crazy macros or flags to memorize\. Not bad right? Well not all flags are bad, in fact, you also get some super\-helpful optional ones for the other 10%, just look above at the OPTIONS section\.
|
81
|
+
.
|
82
|
+
.P
|
83
|
+
Oh yeah, make sure your terminal has \fBgrep\fR, \fBfind\fR, and \fBtree\fR\. It should, but depends on how crazy your \'gear\' is\.
|
84
|
+
.
|
85
|
+
.SH "PREFERENCES"
|
86
|
+
Preferences are saved in \'~/\.peter\-notes\.yml\'\. There are just 2 options that you can set:
|
87
|
+
.
|
88
|
+
.IP "" 4
|
89
|
+
.
|
90
|
+
.nf
|
91
|
+
|
92
|
+
editor:
|
93
|
+
The editor of your choice\. This value will get passed to bash so
|
94
|
+
make sure you use the exact name your terminal will understand\.
|
95
|
+
Possible Values: [\'vim\', \'subl\', \'atom\', \'emacs\', \'nano\']
|
96
|
+
(more?) I haven\'t tested others and dont know
|
97
|
+
which work well when opening a directory\. For
|
98
|
+
vim I use the NerdTree plugin\.
|
99
|
+
Default Value: \'vim\'
|
100
|
+
|
101
|
+
notes_dir:
|
102
|
+
The home of your notes\. This is where `peter\-notes` will look
|
103
|
+
for them\.
|
104
|
+
Possible Values: any valid + existing dorectory path\. I use
|
105
|
+
\'~/GoogleDrive/Notes\' because I track mine in
|
106
|
+
google drive (OverGrive for linux)\.
|
107
|
+
Default Value: \'~/Notes\'
|
108
|
+
.
|
109
|
+
.fi
|
110
|
+
.
|
111
|
+
.IP "" 0
|
112
|
+
.
|
113
|
+
.P
|
114
|
+
That\'s yaml \fIhttp://www\.yaml\.org/start\.html\fR so it should look like this:
|
115
|
+
.
|
116
|
+
.IP "" 4
|
117
|
+
.
|
118
|
+
.nf
|
119
|
+
|
120
|
+
editor: vim
|
121
|
+
notes_dir: /home/peter/Notes
|
122
|
+
.
|
123
|
+
.fi
|
124
|
+
.
|
125
|
+
.IP "" 0
|
126
|
+
.
|
127
|
+
.SH "AUTHORS"
|
128
|
+
Peter Fonseca \fIpeter\.nfonseca@gmail\.com\fR
|
129
|
+
.
|
130
|
+
.SH "SEE ALSO"
|
131
|
+
This tool runs on top of a few very useful bash utilities and relies on terminal\-accessible text\-editors\. It was also written in a fantastic language called ruby\.
|
132
|
+
.
|
133
|
+
.P
|
134
|
+
bash(1), grep(1), find(1), tree(1), vim(1), ruby(1)
|
@@ -0,0 +1,181 @@
|
|
1
|
+
<!DOCTYPE html>
|
2
|
+
<html>
|
3
|
+
<head>
|
4
|
+
<meta http-equiv='content-type' value='text/html;charset=utf8'>
|
5
|
+
<meta name='generator' value='Ronn/v0.7.3 (http://github.com/rtomayko/ronn/tree/0.7.3)'>
|
6
|
+
<title>peter-notes(1) - manage your notes from the terminal</title>
|
7
|
+
<style type='text/css' media='all'>
|
8
|
+
/* style: man */
|
9
|
+
body#manpage {margin:0}
|
10
|
+
.mp {max-width:100ex;padding:0 9ex 1ex 4ex}
|
11
|
+
.mp p,.mp pre,.mp ul,.mp ol,.mp dl {margin:0 0 20px 0}
|
12
|
+
.mp h2 {margin:10px 0 0 0}
|
13
|
+
.mp > p,.mp > pre,.mp > ul,.mp > ol,.mp > dl {margin-left:8ex}
|
14
|
+
.mp h3 {margin:0 0 0 4ex}
|
15
|
+
.mp dt {margin:0;clear:left}
|
16
|
+
.mp dt.flush {float:left;width:8ex}
|
17
|
+
.mp dd {margin:0 0 0 9ex}
|
18
|
+
.mp h1,.mp h2,.mp h3,.mp h4 {clear:left}
|
19
|
+
.mp pre {margin-bottom:20px}
|
20
|
+
.mp pre+h2,.mp pre+h3 {margin-top:22px}
|
21
|
+
.mp h2+pre,.mp h3+pre {margin-top:5px}
|
22
|
+
.mp img {display:block;margin:auto}
|
23
|
+
.mp h1.man-title {display:none}
|
24
|
+
.mp,.mp code,.mp pre,.mp tt,.mp kbd,.mp samp,.mp h3,.mp h4 {font-family:monospace;font-size:14px;line-height:1.42857142857143}
|
25
|
+
.mp h2 {font-size:16px;line-height:1.25}
|
26
|
+
.mp h1 {font-size:20px;line-height:2}
|
27
|
+
.mp {text-align:justify;background:#fff}
|
28
|
+
.mp,.mp code,.mp pre,.mp pre code,.mp tt,.mp kbd,.mp samp {color:#131211}
|
29
|
+
.mp h1,.mp h2,.mp h3,.mp h4 {color:#030201}
|
30
|
+
.mp u {text-decoration:underline}
|
31
|
+
.mp code,.mp strong,.mp b {font-weight:bold;color:#131211}
|
32
|
+
.mp em,.mp var {font-style:italic;color:#232221;text-decoration:none}
|
33
|
+
.mp a,.mp a:link,.mp a:hover,.mp a code,.mp a pre,.mp a tt,.mp a kbd,.mp a samp {color:#0000ff}
|
34
|
+
.mp b.man-ref {font-weight:normal;color:#434241}
|
35
|
+
.mp pre {padding:0 4ex}
|
36
|
+
.mp pre code {font-weight:normal;color:#434241}
|
37
|
+
.mp h2+pre,h3+pre {padding-left:0}
|
38
|
+
ol.man-decor,ol.man-decor li {margin:3px 0 10px 0;padding:0;float:left;width:33%;list-style-type:none;text-transform:uppercase;color:#999;letter-spacing:1px}
|
39
|
+
ol.man-decor {width:100%}
|
40
|
+
ol.man-decor li.tl {text-align:left}
|
41
|
+
ol.man-decor li.tc {text-align:center;letter-spacing:4px}
|
42
|
+
ol.man-decor li.tr {text-align:right;float:right}
|
43
|
+
</style>
|
44
|
+
</head>
|
45
|
+
<!--
|
46
|
+
The following styles are deprecated and will be removed at some point:
|
47
|
+
div#man, div#man ol.man, div#man ol.head, div#man ol.man.
|
48
|
+
|
49
|
+
The .man-page, .man-decor, .man-head, .man-foot, .man-title, and
|
50
|
+
.man-navigation should be used instead.
|
51
|
+
-->
|
52
|
+
<body id='manpage'>
|
53
|
+
<div class='mp' id='man'>
|
54
|
+
|
55
|
+
<div class='man-navigation' style='display:none'>
|
56
|
+
<a href="#NAME">NAME</a>
|
57
|
+
<a href="#SYNOPSIS">SYNOPSIS</a>
|
58
|
+
<a href="#DESCRIPTION">DESCRIPTION</a>
|
59
|
+
<a href="#OPTIONS">OPTIONS</a>
|
60
|
+
<a href="#EXAMPLES">EXAMPLES</a>
|
61
|
+
<a href="#PREFERENCES">PREFERENCES</a>
|
62
|
+
<a href="#AUTHORS">AUTHORS</a>
|
63
|
+
<a href="#SEE-ALSO">SEE ALSO</a>
|
64
|
+
</div>
|
65
|
+
|
66
|
+
<ol class='man-decor man-head man head'>
|
67
|
+
<li class='tl'>peter-notes(1)</li>
|
68
|
+
<li class='tc'></li>
|
69
|
+
<li class='tr'>peter-notes(1)</li>
|
70
|
+
</ol>
|
71
|
+
|
72
|
+
<h2 id="NAME">NAME</h2>
|
73
|
+
<p class="man-name">
|
74
|
+
<code>peter-notes</code> - <span class="man-whatis">manage your notes from the terminal</span>
|
75
|
+
</p>
|
76
|
+
|
77
|
+
<h2 id="SYNOPSIS">SYNOPSIS</h2>
|
78
|
+
|
79
|
+
<p><code>notes</code> [<var>FILE-GLOB</var>] <br />
|
80
|
+
<code>notes</code> <code>-s</code>|<code>--search</code> <var>REGEX</var> <br />
|
81
|
+
<code>notes</code> <code>-f</code>|<code>--find</code> <var>FILE-GLOB</var> <br />
|
82
|
+
<code>notes</code> <code>-l</code>|<code>--list</code> [<var>PATH</var>] <br /></p>
|
83
|
+
|
84
|
+
<h2 id="DESCRIPTION">DESCRIPTION</h2>
|
85
|
+
|
86
|
+
<p>This document describes the <strong>peter-notes</strong> tool. This simple ruby
|
87
|
+
gem is an awesome way to manage personal notes from the terminal.</p>
|
88
|
+
|
89
|
+
<h2 id="OPTIONS">OPTIONS</h2>
|
90
|
+
|
91
|
+
<p>These options provide some extra utility beyond simply opening notes
|
92
|
+
for editing.</p>
|
93
|
+
|
94
|
+
<dl>
|
95
|
+
<dt><code>-s</code>, <code>--search <REGEX></code></dt><dd><p>Search within notes for text matching the specified <code>REGEX</code>. If you havent guessed, this is the <a href="http://linuxcommand.org/man_pages/grep1.html">grep</a> part. Specifically, its running <code>grep -r YOUR-NOTES-DIR -e REGEX</code>.</p></dd>
|
96
|
+
<dt><code>-f</code>, <code>--find <FILE-GLOB></code></dt><dd><p>Seach for notes that match the specified file-glob. This ones running <a href="http://linuxcommand.org/man_pages/find1.html">find</a> -- <code>find YOUR-NOTES-DIR -name FILE-GLOB</code>. Its a little more than that though, this will be fuzzy in that you can add some path info to your glob. For example, if you ran <code>notes --find "projects/*.txt"</code>, youd get back both <code>projects/python/jarbs.txt</code> and <code>projects/ruby/peter_notes.txt</code>. So its better than just find. A little.</p></dd>
|
97
|
+
<dt><code>-l</code>, <code>--list [<PATH>]</code></dt><dd><p>List all notes or, if a <code>PATH</code> is specified, list notes within the specified path. Bet you thought this was running <code>ls -r</code>, well its actually running <a href="http://linuxcommand.org/man_pages/tree1.html">tree</a> because its much cooler -- <code>tree YOUR-NOTES-DIR/PATH</code>.</p></dd>
|
98
|
+
</dl>
|
99
|
+
|
100
|
+
|
101
|
+
<h2 id="EXAMPLES">EXAMPLES</h2>
|
102
|
+
|
103
|
+
<p><code>notes</code>. Yeah.</p>
|
104
|
+
|
105
|
+
<p>But you can do more!</p>
|
106
|
+
|
107
|
+
<p>Lets assume you have the following notes:</p>
|
108
|
+
|
109
|
+
<pre><code>/Users/peter/Notes/
|
110
|
+
|-- projects
|
111
|
+
| |-- python
|
112
|
+
| | +-- jarbs.txt
|
113
|
+
| +-- ruby
|
114
|
+
| +-- peter_notes.txt
|
115
|
+
+-- other
|
116
|
+
+-- motorcycle.txt
|
117
|
+
</code></pre>
|
118
|
+
|
119
|
+
<p>Most of the time you just want to open them. To do that, just type <code>notes</code>. You can specify your text editor and where your notes are in <code>~/peter-notes.yaml</code> (see the preferences section below).</p>
|
120
|
+
|
121
|
+
<p>If you want to open a specific note, you can pass in a <code>file-glob</code> to specify which notes you want to open. If you think a file glob is what happens when you spill coffee on your computer, just check this out <a href="http://tldp.org/LDP/abs/html/globbingref.html">this</a> or google it (hint, you use it in bash a lot, like, when you <code>ls *.rb</code>).</p>
|
122
|
+
|
123
|
+
<p>If you just want to open <code>other/motorcycle.txt</code> you can run <code>notes "other/motorcycle.txt"</code>. But thats kind of lame, so you could also fo <code>notes "motorcycle.txt"</code>, or even <code>notes "moto*"</code>. If youre feeling extra crazy, you could even get away with <code>m*</code> in this case, basically if you pass a glob in, <code>peter-notes</code> will just take the first match in <code>--find</code> (see below) and open that.</p>
|
124
|
+
|
125
|
+
<p>If you wanted to open all notes under <code>projects/</code> you could also use this same idea and run <code>notes "projects"</code>.</p>
|
126
|
+
|
127
|
+
<p>Thats like what 90% of what youll ever need and no crazy macros or flags to memorize. Not bad right? Well not all flags are bad, in fact, you also get some super-helpful optional ones for the other 10%, just look above at the OPTIONS section.</p>
|
128
|
+
|
129
|
+
<p>Oh yeah, make sure your terminal has <code>grep</code>, <code>find</code>, and <code>tree</code>. It should, but depends on how crazy your 'gear' is.</p>
|
130
|
+
|
131
|
+
<h2 id="PREFERENCES">PREFERENCES</h2>
|
132
|
+
|
133
|
+
<p>Preferences are saved in '~/.peter-notes.yml'. There are just 2
|
134
|
+
options that you can set:</p>
|
135
|
+
|
136
|
+
<pre><code>editor:
|
137
|
+
The editor of your choice. This value will get passed to bash so
|
138
|
+
make sure you use the exact name your terminal will understand.
|
139
|
+
Possible Values: ['vim', 'subl', 'atom', 'emacs', 'nano']
|
140
|
+
(more?) I haven't tested others and dont know
|
141
|
+
which work well when opening a directory. For
|
142
|
+
vim I use the NerdTree plugin.
|
143
|
+
Default Value: 'vim'
|
144
|
+
|
145
|
+
notes_dir:
|
146
|
+
The home of your notes. This is where `peter-notes` will look
|
147
|
+
for them.
|
148
|
+
Possible Values: any valid + existing dorectory path. I use
|
149
|
+
'~/GoogleDrive/Notes' because I track mine in
|
150
|
+
google drive (OverGrive for linux).
|
151
|
+
Default Value: '~/Notes'
|
152
|
+
</code></pre>
|
153
|
+
|
154
|
+
<p>That's <a href="http://www.yaml.org/start.html">yaml</a> so it should look like this:</p>
|
155
|
+
|
156
|
+
<pre><code>editor: vim
|
157
|
+
notes_dir: /home/peter/Notes
|
158
|
+
</code></pre>
|
159
|
+
|
160
|
+
<h2 id="AUTHORS">AUTHORS</h2>
|
161
|
+
|
162
|
+
<p>Peter Fonseca <a href="mailto:peter.nfonseca@gmail.com" data-bare-link="true">peter.nfonseca@gmail.com</a></p>
|
163
|
+
|
164
|
+
<h2 id="SEE-ALSO">SEE ALSO</h2>
|
165
|
+
|
166
|
+
<p>This tool runs on top of a few very useful bash utilities and relies
|
167
|
+
on terminal-accessible text-editors. It was also written in a
|
168
|
+
fantastic language called ruby.</p>
|
169
|
+
|
170
|
+
<p><span class="man-ref">bash<span class="s">(1)</span></span>, <span class="man-ref">grep<span class="s">(1)</span></span>, <span class="man-ref">find<span class="s">(1)</span></span>, <span class="man-ref">tree<span class="s">(1)</span></span>, <span class="man-ref">vim<span class="s">(1)</span></span>, <span class="man-ref">ruby<span class="s">(1)</span></span></p>
|
171
|
+
|
172
|
+
|
173
|
+
<ol class='man-decor man-foot man foot'>
|
174
|
+
<li class='tl'></li>
|
175
|
+
<li class='tc'>June 2017</li>
|
176
|
+
<li class='tr'>peter-notes(1)</li>
|
177
|
+
</ol>
|
178
|
+
|
179
|
+
</div>
|
180
|
+
</body>
|
181
|
+
</html>
|
@@ -0,0 +1,98 @@
|
|
1
|
+
peter-notes(1) -- manage your notes from the terminal
|
2
|
+
=============================================
|
3
|
+
|
4
|
+
## SYNOPSIS
|
5
|
+
|
6
|
+
`notes` [<FILE-GLOB>] <br>
|
7
|
+
`notes` `-s`|`--search` <REGEX> <br>
|
8
|
+
`notes` `-f`|`--find` <FILE-GLOB> <br>
|
9
|
+
`notes` `-l`|`--list` [<PATH>] <br>
|
10
|
+
|
11
|
+
## DESCRIPTION
|
12
|
+
|
13
|
+
This document describes the **peter-notes** tool. This simple ruby
|
14
|
+
gem is an awesome way to manage personal notes from the terminal.
|
15
|
+
|
16
|
+
## OPTIONS
|
17
|
+
|
18
|
+
These options provide some extra utility beyond simply opening notes
|
19
|
+
for editing.
|
20
|
+
|
21
|
+
* `-s`, `--search <REGEX>`:
|
22
|
+
Search within notes for text matching the specified `REGEX`. If you havent guessed, this is the [grep](http://linuxcommand.org/man_pages/grep1.html) part. Specifically, its running `grep -r YOUR-NOTES-DIR -e REGEX`.
|
23
|
+
|
24
|
+
* `-f`, `--find <FILE-GLOB>`:
|
25
|
+
Seach for notes that match the specified file-glob. This ones running [find](http://linuxcommand.org/man_pages/find1.html) -- `find YOUR-NOTES-DIR -name FILE-GLOB`. Its a little more than that though, this will be fuzzy in that you can add some path info to your glob. For example, if you ran `notes --find "projects/*.txt"`, youd get back both `projects/python/jarbs.txt` and `projects/ruby/peter_notes.txt`. So its better than just find. A little.
|
26
|
+
|
27
|
+
|
28
|
+
* `-l`, `--list [<PATH>]`:
|
29
|
+
List all notes or, if a `PATH` is specified, list notes within the specified path. Bet you thought this was running `ls -r`, well its actually running [tree](http://linuxcommand.org/man_pages/tree1.html) because its much cooler -- `tree YOUR-NOTES-DIR/PATH`.
|
30
|
+
|
31
|
+
|
32
|
+
## EXAMPLES
|
33
|
+
|
34
|
+
`notes`. Yeah.
|
35
|
+
|
36
|
+
But you can do more!
|
37
|
+
|
38
|
+
Lets assume you have the following notes:
|
39
|
+
|
40
|
+
/Users/peter/Notes/
|
41
|
+
|-- projects
|
42
|
+
| |-- python
|
43
|
+
| | +-- jarbs.txt
|
44
|
+
| +-- ruby
|
45
|
+
| +-- peter_notes.txt
|
46
|
+
+-- other
|
47
|
+
+-- motorcycle.txt
|
48
|
+
|
49
|
+
Most of the time you just want to open them. To do that, just type `notes`. You can specify your text editor and where your notes are in `~/peter-notes.yaml` (see the preferences section below).
|
50
|
+
|
51
|
+
If you want to open a specific note, you can pass in a `file-glob` to specify which notes you want to open. If you think a file glob is what happens when you spill coffee on your computer, just check this out [this](http://tldp.org/LDP/abs/html/globbingref.html) or google it (hint, you use it in bash a lot, like, when you `ls *.rb`).
|
52
|
+
|
53
|
+
If you just want to open `other/motorcycle.txt` you can run `notes "other/motorcycle.txt"`. But thats kind of lame, so you could also fo `notes "motorcycle.txt"`, or even `notes "moto*"`. If youre feeling extra crazy, you could even get away with `m*` in this case, basically if you pass a glob in, `peter-notes` will just take the first match in `--find` (see below) and open that.
|
54
|
+
|
55
|
+
If you wanted to open all notes under `projects/` you could also use this same idea and run `notes "projects"`.
|
56
|
+
|
57
|
+
Thats like what 90% of what youll ever need and no crazy macros or flags to memorize. Not bad right? Well not all flags are bad, in fact, you also get some super-helpful optional ones for the other 10%, just look above at the OPTIONS section.
|
58
|
+
|
59
|
+
Oh yeah, make sure your terminal has `grep`, `find`, and `tree`. It should, but depends on how crazy your 'gear' is.
|
60
|
+
|
61
|
+
## PREFERENCES
|
62
|
+
|
63
|
+
Preferences are saved in '~/.peter-notes.yml'. There are just 2
|
64
|
+
options that you can set:
|
65
|
+
|
66
|
+
editor:
|
67
|
+
The editor of your choice. This value will get passed to bash so
|
68
|
+
make sure you use the exact name your terminal will understand.
|
69
|
+
Possible Values: ['vim', 'subl', 'atom', 'emacs', 'nano']
|
70
|
+
(more?) I haven't tested others and dont know
|
71
|
+
which work well when opening a directory. For
|
72
|
+
vim I use the NerdTree plugin.
|
73
|
+
Default Value: 'vim'
|
74
|
+
|
75
|
+
notes_dir:
|
76
|
+
The home of your notes. This is where `peter-notes` will look
|
77
|
+
for them.
|
78
|
+
Possible Values: any valid + existing dorectory path. I use
|
79
|
+
'~/GoogleDrive/Notes' because I track mine in
|
80
|
+
google drive (OverGrive for linux).
|
81
|
+
Default Value: '~/Notes'
|
82
|
+
|
83
|
+
That's [yaml](http://www.yaml.org/start.html) so it should look like this:
|
84
|
+
|
85
|
+
editor: vim
|
86
|
+
notes_dir: /home/peter/Notes
|
87
|
+
|
88
|
+
## AUTHORS
|
89
|
+
|
90
|
+
Peter Fonseca <peter.nfonseca@gmail.com>
|
91
|
+
|
92
|
+
## SEE ALSO
|
93
|
+
|
94
|
+
This tool runs on top of a few very useful bash utilities and relies
|
95
|
+
on terminal-accessible text-editors. It was also written in a
|
96
|
+
fantastic language called ruby.
|
97
|
+
|
98
|
+
bash(1), grep(1), find(1), tree(1), vim(1), ruby(1)
|
data/peter-notes.gemspec
ADDED
@@ -0,0 +1,30 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path("../lib", __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require "peter_notes/version"
|
5
|
+
|
6
|
+
Gem::Specification.new do |spec|
|
7
|
+
spec.name = "peter-notes"
|
8
|
+
spec.version = PeterNotes::VERSION
|
9
|
+
spec.authors = ["Peter Fonseca"]
|
10
|
+
spec.email = ["peter.nfonseca@gmail.com"]
|
11
|
+
|
12
|
+
spec.summary = %q{Lightweight notes manager}
|
13
|
+
spec.description = %q{Manage notes with this minimal gem. You can choose your editor and organize your notes however you choose. If you want to track your notes, this gem will stay out of the way. It's a cli tool, don't try to import it in a ruby file.}
|
14
|
+
spec.homepage = "https://github.com/fonsecapeter/peter-notes"
|
15
|
+
spec.license = "MIT"
|
16
|
+
|
17
|
+
spec.files = `git ls-files -z`.split("\x0").reject do |f|
|
18
|
+
f.match(%r{^(test|spec|features)/})
|
19
|
+
end
|
20
|
+
spec.bindir = "bin"
|
21
|
+
spec.executables = ["notes"]
|
22
|
+
spec.require_paths = ["lib"]
|
23
|
+
|
24
|
+
spec.add_development_dependency "bundler", "~> 1.15"
|
25
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
26
|
+
spec.add_development_dependency "rspec", "~> 3.0"
|
27
|
+
spec.add_development_dependency "ronn", "~> 0.7.3"
|
28
|
+
spec.add_development_dependency "pry", "~> 0.10.4"
|
29
|
+
spec.add_development_dependency "simplecov-console", "~> 0.4.2"
|
30
|
+
end
|
metadata
ADDED
@@ -0,0 +1,153 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: peter-notes
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Peter Fonseca
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2017-06-28 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: bundler
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '1.15'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.15'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '10.0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '10.0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rspec
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '3.0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '3.0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: ronn
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 0.7.3
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: 0.7.3
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: pry
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 0.10.4
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 0.10.4
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: simplecov-console
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - "~>"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: 0.4.2
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - "~>"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: 0.4.2
|
97
|
+
description: Manage notes with this minimal gem. You can choose your editor and organize
|
98
|
+
your notes however you choose. If you want to track your notes, this gem will stay
|
99
|
+
out of the way. It's a cli tool, don't try to import it in a ruby file.
|
100
|
+
email:
|
101
|
+
- peter.nfonseca@gmail.com
|
102
|
+
executables:
|
103
|
+
- notes
|
104
|
+
extensions: []
|
105
|
+
extra_rdoc_files: []
|
106
|
+
files:
|
107
|
+
- ".gitignore"
|
108
|
+
- ".rspec"
|
109
|
+
- ".travis.yml"
|
110
|
+
- CODE_OF_CONDUCT.md
|
111
|
+
- Gemfile
|
112
|
+
- LICENSE.txt
|
113
|
+
- README.md
|
114
|
+
- Rakefile
|
115
|
+
- bin/console
|
116
|
+
- bin/notes
|
117
|
+
- bin/ronn
|
118
|
+
- bin/setup
|
119
|
+
- bin/test
|
120
|
+
- lib/models/console_app.rb
|
121
|
+
- lib/models/notes.rb
|
122
|
+
- lib/models/preferences.rb
|
123
|
+
- lib/peter_notes/peter_notes.rb
|
124
|
+
- lib/peter_notes/version.rb
|
125
|
+
- man/peter-notes.7
|
126
|
+
- man/peter-notes.7.html
|
127
|
+
- man/peter-notes.7.ronn
|
128
|
+
- peter-notes.gemspec
|
129
|
+
homepage: https://github.com/fonsecapeter/peter-notes
|
130
|
+
licenses:
|
131
|
+
- MIT
|
132
|
+
metadata: {}
|
133
|
+
post_install_message:
|
134
|
+
rdoc_options: []
|
135
|
+
require_paths:
|
136
|
+
- lib
|
137
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
138
|
+
requirements:
|
139
|
+
- - ">="
|
140
|
+
- !ruby/object:Gem::Version
|
141
|
+
version: '0'
|
142
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
143
|
+
requirements:
|
144
|
+
- - ">="
|
145
|
+
- !ruby/object:Gem::Version
|
146
|
+
version: '0'
|
147
|
+
requirements: []
|
148
|
+
rubyforge_project:
|
149
|
+
rubygems_version: 2.6.12
|
150
|
+
signing_key:
|
151
|
+
specification_version: 4
|
152
|
+
summary: Lightweight notes manager
|
153
|
+
test_files: []
|