Skip to main content

A tool to show terminal tutorials.

Project description

Build Status

Tutorterminal

A tool to create scripts to help and learn command line tools.

# Hashs are used to describe text that will be shown to the user.
#
# !checkfile command checks that a file not exists and allow you to continue the script
!checkfile .git
#
# <bold><green>You can use ANSIMARKUP to format your text</green></bold>
#
## Double hashs mark text that are related and used as a help for the next command/input.
#
# run command prompts the user for a command that match the regex indicated...
run git init$
#
# And then you can check if a file exists:
checkfile .git
#
# You can ask the user to press ENTER to continue
enter
#
# And also automatically create a file (example.txt):
### exemple.txt
Arquivo de exemplo com 3 linhas:
Linha 0
Linha 1
Linha 2
###
#
# You can automatically run a command for the user with run_auto
#
run_auto ls
#
# And allow the user to run any command with run_free
run_free 

Commands

#

# Anything to be displayed

Displays a text to the user. You can use ansimarkups to format text.

##

## Anything to be displayed

TODO A text displayed to the user that can be invoked by the help command.

###

### filename
file content
may have any number of lines
###

Command to create a file that will include any text from that command until the next ###.

checkfile and !checkfile

checkfile file_or_directory_to_be_checked if it exists
!checkfile file_or_directory_to_be_checked if it not exists

Checks if a file or directory exists (or not). If condition is not satisfied, the script will stop.

run

run regex_of_command

Create a user prompt where user must type a command that satisfies the regex passed as argument.

run_auto

run_auto command

Runs an command automatically as an user would (the prompt and command are displayed to the user).

run_free

run_free

Allow user to run any command.

Running tutorterminal

To run tutorterminal execute: python3 learn_script.py [files]

tutorTermianlGit

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tutorterminal-0.1.tar.gz (4.3 kB view details)

Uploaded Source

File details

Details for the file tutorterminal-0.1.tar.gz.

File metadata

  • Download URL: tutorterminal-0.1.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.1.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.5

File hashes

Hashes for tutorterminal-0.1.tar.gz
Algorithm Hash digest
SHA256 2baf4d36331adce9725bd3810bd6d9058d40cd4cbeae4c77466a75f977dc0049
MD5 ce5b18e50577356b8f1c43b0c006e43a
BLAKE2b-256 9f472809f4705dce4d3bb512192c60599cdef6883c446ad013081c47d53f35a9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page