schedule: "5 4 * * *" # Run daily at 04:05.

env:
  - PATH: "$PATH"
  - APP_DIR: /home/app
  - CONFIG_FILE: "$CONFIG_FILE"
  - GIT_REPOSITORIES_DIR: "$GIT_REPOSITORIES_DIR"
  - DATASET_DIR: "$DATASET_DIR"
  - HOME: "$HOME"
steps:
  - name: update repositories
    dir: $APP_DIR
    command: python -m tabby.tools.repository.updater --data_dir=$GIT_REPOSITORIES_DIR --config_file=$CONFIG_FILE

  - name: generate dataset
    dir: $APP_DIR
    command: python -m tabby.tools.build_dataset --project_dir=$GIT_REPOSITORIES_DIR --output_dir=$DATASET_DIR
    depends:
      - update repositories
