Commit graph

4 commits

Author SHA1 Message Date
Jonathan Hodgson
660c739c18 Moves safeSQL function to utils 2020-12-20 18:28:19 +00:00
Jonathan Hodgson
b84cf93f4a Adds list-tags option
This will list the tags along with the number of number of times it is
used.

An optional --noheader flag can be passed after the command to prevent
the header being printed.

e.g.

```
$ kb list-tags
name              count
----------------  -----
Linux             2
Authentication    1
Pentesting        1
Enumeration       3
Network Protocol  2
```

```
$ kb list-tags --noheader
Linux             2
Authentication    1
Pentesting        1
Enumeration       3
Network Protocol  2
```

This --noheader flag was also added to the list command

Close #10
2020-12-20 18:25:25 +00:00
Jonathan Hodgson
ac031344d3 Splits up file into smaller files
Closes issue #9
2020-12-20 17:07:17 +00:00
Jonathan Hodgson
8ddda7f2b4 This is the initial commit. See description for what currently works
Currently Working:
* creating files
* deleting files
* editing files
* viewing files
* searching by id
* git
    - Initialises repository
    - commits when a file is created or edited (except rename)
    - arbitrary git commands on repo with `kb git ....`
* sql
    - Database is kept up to date when files are added, deleted or
      edited

TODO:
* Recreate database if deleted or freshly cloned
* Add database to gitignore if not in normal location
* Update database if edited without this tool
* Create a git commit if files are deleted or renamed
* makefile for install and test (currently just surecheck)
2020-12-19 15:52:27 +00:00