garden-tools 2.6.0

Garden grows and cultivates collections of Git trees Garden lets you define and run commands over collections of configuration-defined multi-worktree Git environments.
Documentation
# Demo using "python3" as the interpreter for custom commands.
garden:
  shell: python3

commands:
  hello: |
    import sys
    # dash_c = sys.argv[0]  # sys.argv[0] contains '-c'
    args = sys.argv[1:]  # additional arguments specified after '--'
    if args:
        world = ' '.join(args)
    else:
        world = 'world'
    print(f'hello {world}')

  info: |
    import os
    import sys
    print(f'os.name = {os.name}')
    print(f'sys.platform = {sys.platform}')
    print(r'sys.int_info = {sys.int_info}')
    print('uname = ${uname}')

variables:
  # NOTE: exec expressions are always run using the system's default #!/bin/sh shell.
  uname: $ uname -a