Skip to content

Latest commit

 

History

History
153 lines (123 loc) · 3.99 KB

template.org

File metadata and controls

153 lines (123 loc) · 3.99 KB

CHANGEME

Folder (temp and otherwise)

In Org Folder

shell

pwd

tmate

pwd

In Temp Folder

pwd

pwd

Example Code Block Modifications

Std Err

Capturing Errors (on stderr)

Shell code blocks will now prefix / postfix with exec where stderr is redirected to stdout and captured.

exec 2>&1

and appending:

:

Feeding blocks to a command

Each of the following code blocks will be fed to an application via HEREDOC. The example here is big query.

exec 2>&1
bq query -n 2000 --nouse_legacy_sql  <<EOF

and appending:

EOF
:

The exec + : ensure that stderr is captured. We add bq and params feed the code block to big query.

Footer

Each of the following code blocks will be fed to big query via prefixing

exec 2>&1

and appending:

:

Local Variables Notes

The exec + : ensure that stderr is capture.

org-file-dir is the directory this file exists in user-buffer is $USER.$FILENAME without .org ie. hh.filenamebase socket is /tmp/$USER.$FILENAMEBASE.ii.socket we copy the tmate command to clipboard and primary tmpdir creates folder in the ramdisk on load :async yes to enable async execution As soon as you load this file, create a new terminal and paste to create target tmate session