Skip to main content

Table 9 CLI examples

From: kegg_pull: a software package for the RESTful access and pulling from the Kyoto Encyclopedia of Gene and Genomes

Action

Examples

Pull Entries

cat entry-ids.txt | kegg_pull pull entry-ids -

–multi-process –n-workers = 4 –output = kegg-entries.zip

–entry-field = mol

Pull entry IDs

kegg_pull entry-ids database hsa

REST operation

kegg_pull rest find drug –exact-mass = 200

–exact-mass = 220

  1. Example terminal commands from the CLI. The above terminal commands are analogous to the corresponding lines of code in Table 8. Notice that the analogous CLI commands can do in one line what took the API several lines of code. Also note that there is no distinction between a multiple pull or single pull in the CLI. Under the hood, the CLI uses a concrete class of AbstractMultiplePull for all pulls since it can handle any number of entries, including only one entry