Fork me on GitHub

slipknot

about | install | documentation | user-created databases | credits | screenshots

Table of Contents

  1. Getting started
  2. Using nested databases
  3. Reserved commands
  4. Reporting issues

Getting started

This is the part where I get into the nitty-gritties of how this software works. If you want to know how to use this software, you're in the right place. If you're looking for how to install it, go here (or click the install tab, at the top of the page).

Let's get started.

You've seen this image before, if you've been on the About page. If you haven't read the About page yet, I recommend you start there.

The Slipknot shell accepts the user's input on the command line. It then searches through a database, looking for keys that match the user's input. Finding a key, it will execute the other half of the key. Not finding a key, it will send the input, unchanged, to the operating system for execution.

It should be noted that while you can make more than one key link to the same command, but you can't make one key link to more than one command. Put another way:
x = exit
exit = exit
close = exit

works, but

x = exit
x = rmdir

doesn't work.

Making Multiple Databases

Here's where things get fun, and here's the thing that sets this setup apart from other command line aliasing methods: you're not limited to one database.

Let me say it again for the peeople in the back: you're not limited to one database.

So, for the sake of explanation: you have a set of keys that you use together frequently. A common organizational scheme would be to group them together, using the same prefix with each, like this:

You get the idea.

But this is a pain. Slipknot changes this. You can add a database called fu, switch into it, and then use the keys bar, snob, one and donuts (which are defined in the context of the database fu). To do this, you would add a key to your default database that connects to a database file instead of a command. This database file must exist already, and it must have a file extension of .db. Using this key results in you being switched into the other database, which in turn opens up the keys in that database. It does turn off the keys from the first database, which means that the same key can mean the different things in different databases. This can get confusing very quickly. Being careful is advised.

Is this making any sense? No? TL;DR: you can nest databases. Add a key to one database, containing the location of the other database. Put in the name of the key the same as any other key. This will switch you into the new database.

Reserved commands

There are a few commands that are reserved for the use of Slipknot. They are:

These commands are meant to be used. In fact, they provide critical functionality. These commands are internal. Perhaps this will be be easier to explain if I put my previous list into a table.

command purpose
default returns the Slipknot session to the default database
help prints the current database to the screen, so that you can find that key you need
edit-db wizard for adding a key to the database
exit closes the session
reset resets the session, clearing the screen

I highly recommend adding all of these keys to all of your databases, in some form or another. At this point, there is no overarching configuration file that will make a set of keys work in all databases. You will have to add each of the commands that you would like to use in a given database. I'm working on a fix.

Reporting issues

If you run into an issue, left me know. My email address is cole.webb@outlook.com. You could also file an issue on GitHub, or you could fork it, fix the problem, and then submit a pull request. If you have the skills and the time, I really would appreciate the help. Thank you!

~ Cole Webb, September 25th, 2016