0.0.8 • Published 3 years ago

ttws-cli v0.0.8

Weekly downloads
-
License
MIT
Repository
github
Last release
3 years ago

ttws-cli

Tabletop Workspace Game Compiler

oclif Version Downloads/week License

Usage

$ npm install -g ttws-cli
$ ttws COMMAND
running command...
$ ttws (-v|--version|version)
ttws-cli/0.0.7 win32-x64 node-v14.17.2
$ ttws --help [COMMAND]
USAGE
  $ ttws COMMAND
...

Commands

ttws fetch:keyforge [DECK]

fetch keyforge decks.

USAGE
  $ ttws fetch:keyforge [DECK]

ARGUMENTS
  DECK  url to deck on decksofkeyforge or keyforgegame.

OPTIONS
  -d, --dump           dumps the deck.json file.
  -h, --help           show CLI help
  -i, --images         download deck images.
  -o, --output=output  [default: .] output folder
  -s, --stamp          create stamps on images.

See code: lib/commands/fetch/keyforge.js

ttws fetch:marvelcdb [DECK]

fetch MarvelCDB decks.

USAGE
  $ ttws fetch:marvelcdb [DECK]

ARGUMENTS
  DECK  url to deck on marvelcdb.com.

OPTIONS
  -e, --extract        extract encounter decks from all_packs.json
  -h, --help           show CLI help
  -o, --output=output  [default: .] output folder
  -p, --packs          fetch all cards into all_packs.json

See code: lib/commands/fetch/marvelcdb.js

ttws generate [FILE]

generate component jsons from xlsx files

USAGE
  $ ttws generate [FILE]

ARGUMENTS
  FILE  [default: data.xlsx] path to an input xlsx file

OPTIONS
  -b, --bundle=bundle  write to a bundle json instead
  -h, --help           show CLI help
  -i, --init           initialize a data.xlsx file and fill in some information for you
  -o, --output=output  [default: .] where to put generated json files

EXAMPLES
  ttws generate --init        	# generates a data.xlsx in the current folder
  ttws generate               	# generates each asset into its own json file
  ttws generate cards.xlsx    	# use cards.xlsx instead of data.xlsx
  ttws generate -b data.json  	# generates a data.json containing all assets

See code: lib/commands/generate.js

ttws indexing [FILE]

create index.json files under each folder

USAGE
  $ ttws indexing [FILE]

ARGUMENTS
  FILE  [default: .] Root folder path

OPTIONS
  -h, --help  show CLI help

See code: lib/commands/indexing.js

ttws serve [ROOT]

launch an http asset server here.

USAGE
  $ ttws serve [ROOT]

ARGUMENTS
  ROOT  [default: .] root path to be served

OPTIONS
  -h, --help       show CLI help
  -n, --name=name  [default: TTWS] name displayed in the asset source config
  -p, --port=port  [default: 1337] port for the http server
  -r, --root=root  [default: content] root of assets
  --https=https    [default: 192.168.0.109+1.pem] path to the pem file. key file must be next to it.

EXAMPLES
  ttws serve            	# serves from current path, with https + portal
  ttws serve -p 3000    	# run on port 3000 instead
  ttws serve --https="" 	# disables https

See code: lib/commands/serve.js

ttws ttsdump [FILE]

dump the TTS save as an extracted json file

USAGE
  $ ttws ttsdump [FILE]

ARGUMENTS
  FILE  [default: .] Folder or .json mod file path.

OPTIONS
  -e, --imgSourceExt=imgSourceExt  [default: .webp] replacement image ext
  -h, --help                       show CLI help
  -i, --imgSource=imgSource        replacement image folder path
  -o, --output=output              [default: --] output filename, -- to print to stdout

EXAMPLES
  ttws ttsdump -o tts.json
  ttws ttsdump Mods/Workshop/12345.json > tts.json
  ttws ttsdump -o tts.json -i webp

See code: lib/commands/ttsdump.js

ttws ttsexpand [FILE]

expand a tts extracted json into a folder structure

USAGE
  $ ttws ttsexpand [FILE]

ARGUMENTS
  FILE  .json file path

OPTIONS
  -h, --help           show CLI help
  -o, --output=output  [default: ./tts] Output folder path

See code: lib/commands/ttsexpand.js

ttws ttstree [FILE]

print the object tree structure of a TTS save file/folder.

USAGE
  $ ttws ttstree [FILE]

ARGUMENTS
  FILE  [default: .] Folder or .json mod file path.

OPTIONS
  -h, --help  show CLI help

See code: lib/commands/ttstree.js

ttws webp [FILE]

generate webp images

USAGE
  $ ttws webp [FILE]

ARGUMENTS
  FILE  [default: .] Input image

OPTIONS
  -f, --force            overwrites existing files.
  -h, --help             show CLI help
  -o, --output=output    [default: $dir/$base.webp] output filename, use $dir, $base and $ext for input filename ref.
  -q, --quality=quality  [default: 75] cwebp quality. 1-100.
  -r, --recursive        handles all images in a folder.

EXAMPLES
  ttws webp image.jpg -q 40 -o image.webp
  ttws webp Mods/Images -r -q 1 -o webp/$base.webp

See code: lib/commands/webp.js