This is a list of the commands that have been planned and whether they've been implemented.
srcd sql
No action associated to this.
global flags for all sub commands:
-v|--verbose: verbose mode on, log everything.
--config: path to the config file.
The config file is optional. By default srcd will look for it in $HOME/.srcd/config.yml. You can use a YAML file to configure the public port bindings of the components containers.
Example config file with the default values:
# Any change in the exposed ports will require you to run srcd init (or stop)components:bblfshd:port: 9432bblfsh_web:port: 8081gitbase_web:port: 8080gitbase:port: 3306daemon:port: 4242
Initializes the srcd environment, starting (or restarting) the srcd-server daemon, and verifying Docker is indeed installed and accessible.
It also records the what directory to use for later analysis with gitbase. This will be either the given argument (only one accepted) or the current directory if none is given.
arguments: working directory. If it's not provided, the current working directory will be used
flags: N/A
Stops all containers used by the source{d} Engine.
arguments: N/A
flags: N/A
Removes all containers and docker volumes used by the source{d} engine.
arguments: N/A
flags:
--with-images: remove docker images too
Shows the version of the current srcd cli binary, as well as the one for the srcd-server running on Docker, and Docker itself.
arguments: N/A
flags: N/A
All of the sub commands under srcd parse provide different kinds of parsing, language classification, and bblfsh driver management.
Parses a file and returns the resulting UAST.
arguments:
path: file to be parsed, only one file supported at a time.
flags:
-l|--lang: skip language classification and force a specific language driver.
-q|--query: an XPath expression that will be applied on the obtained UAST.
-m|--mode: UAST parsing mode: semantic|annotated|native (default "semantic")
Identifies the language of the given file.
arguments:
flags:
Lists all of the drivers already installed on bblfsh together with the version installed.
arguments: N/A
flags: N/A
Opens a sql client to a running gitbase server. If the server is not running, it starts it automatically.
arguments: query: the query to run, if blank an interactive session is opened.
flags: N/A
All of the web subcommands provide web clients for different source{d} tools.
Opens a bblfsh web client.
arguments:
Opens a gitbase web client.
arguments:
The sub commands under srcd components provide management to pre-install, remove, and update the components associated to the source{d} Engine.
For instance, bblfsh and gitbase are some of these components. More will be coming soon. One of them could easily be the Spark engine with Jupyter.
Lists source{d} Engine components
arguments:
flags:
-a|--all: show all versions found
Installs source{d} Engine components images.
arguments:
component: the name of the component image. It must be one of:
bblfsh/bblfshd
bblfsh/web
srcd/cli-daemon
srcd/gitbase-web
srcd/gitbase
flags: N/A
status: ❌ TBD
Start source{d} Engine components and its dependencies if needed.
arguments:
component: the name of the component image. It must be one of:
bblfsh/bblfshd
bblfsh/web
srcd/cli-daemon
srcd/gitbase-web
srcd/gitbase
flags: N/A
status: ❌ TBD
status: ❌ TBD
status: ❌ TBD
status: ❌ TBD