You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
eton/README.md

113 lines
1.7 KiB
Markdown

9 years ago
# eton
9 years ago
eton is a note-taking cli tool.
9 years ago
* sqlite database storage
* fast search
* quick and direct access to a note using a unique alias
* mark important notes
9 years ago
## Install or upgrade
9 years ago
9 years ago
go get -u github.com/siadat/eton
9 years ago
9 years ago
## Usage examples
9 years ago
```shell
# display the help message
eton -h
9 years ago
```
### new
9 years ago
9 years ago
```shell
# quick add
9 years ago
eton new 'eton is simple'
eton new 'https://...'
eton new '[ ] try eton'
9 years ago
9 years ago
# create a new note using $EDITOR
eton new
9 years ago
# add from STDIN
ps aux |eton new -
9 years ago
# add files
eton addfile file1.txt file2.txt
find -type f |eton addfile -
```
9 years ago
9 years ago
### edit
9 years ago
9 years ago
```shell
# edit last item
eton edit
9 years ago
9 years ago
# edit items
eton edit processes 1
```
### alias
```shell
# set a unique alias
9 years ago
eton alias 3 procs
# use the alias, so you don't need to remember its id
eton cat procs
9 years ago
eton edit procs
eton show procs
9 years ago
9 years ago
# rename an alias
eton alias procs processes
9 years ago
9 years ago
# remove an alias
eton unalias processes
```
### mark
9 years ago
9 years ago
```shell
# mark an item
eton mark processes
9 years ago
9 years ago
# unmark an item
eton unmark processes
```
9 years ago
9 years ago
### ls
9 years ago
9 years ago
```shell
# list recent items
eton ls
9 years ago
9 years ago
# filter items containing words "eton" AND "simple"
eton ls eton simple
# list all items
eton ls -a
# only list marked items (short mode)
eton ls -s
9 years ago
# pass items to xargs as filenames:
eton ls '[ ]' -l |xargs -i less {}
```
9 years ago
9 years ago
### more
9 years ago
```shell
9 years ago
# alias matching is fuzzy for these commands: cat, show, edit, mark, unmark
eton cat prs
# view items 1, 2, and 3 using less
eton show 1 2 3
# Notes are stored in `~/.etondb`
echo 'SELECT * FROM attributes LIMIT 10;' |sqlite3 ~/.etondb
```
9 years ago
Set `$EDITOR` environment variable to edit notes in your prefered editor, e.g., `export EDITOR=vim`.
9 years ago
I would love to hear how you use eton. Make pull requests, report bugs, suggest ideas.