Skip to content

Rust/Cargo: Changing a relative dependency source does not invalidate the project hash #1802

Answered by milesj
alexander-heimbuch asked this question in Q&A
Discussion options

You must be logged in to vote

Only task deps are included in a task's hash, not a project's deps. https://moonrepo.dev/docs/config/project#deps

If you want don't want to reference another task in the lib, you can create a "fake" task that is simple used as a touched check.

# lib
tasks:
  touched:
    command: noop

# app 
tasks:
  build:
    command: 'cargo build'
    inputs:
      - '@globs(sources)'
    deps:
      - 'lib:touched'

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@alexander-heimbuch
Comment options

@milesj
Comment options

Answer selected by alexander-heimbuch
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants