hammerkit
  • About
  • Installation
  • Getting started
  • Build file
    • Environment Variables
    • References
    • Includes
  • Task
    • Dependencies
    • Needs
    • Caching
    • Container
    • Watching
    • Extending
  • Service
    • Container
    • Kubernetes
  • Labels
  • CLI
    • Init
    • ls
    • Execute
    • Store / Restore
    • Clean
    • Validate
    • Help
  • External Links
    • Docker Hub
    • Homebrew Repository
  • Release Blog
    • Release 1.4.0
    • Release 1.5.0
  • Contribution
    • Roadmap
    • Publishing
Powered by GitBook
On this page

Was this helpful?

  1. Task

Dependencies

A task can require dependant tasks that will get executed first (if not cached).

PreviousTaskNextNeeds

Last updated 2 years ago

Was this helpful?

Every task can have list of dependencies. Those will be executed before and if any of them fails abort the all pending tasks. Dependencies can be chained as deep as needed, as long as there is no loop.

.hammerkit.yaml
tasks:
  install:
    cmds:
      - npm install
      
  build:
    deps: [install]
    cmds:
      - tsc -b
  
  publish:
    deps: [build]
    cmds:
      - npm publish

Make sure to setup correct to speed up your execution and prevent unnecessary work.

caching