lint-features.mts 580 B

12345678910111213
  1. #!/usr/bin/env zx
  2. import 'zx/globals';
  3. import { getToolchainArgument, parseCliArguments } from '../helpers/utils.mts';
  4. // Extract the crate directory from the command-line arguments.
  5. const { manifestPath, args } = parseCliArguments();
  6. // Configure additional arguments here, e.g.:
  7. // ['--arg1', '--arg2', ...args]
  8. const featuresArgs = ['--exclude-features', 'frozen-abi', ...args];
  9. const toolchain = getToolchainArgument('lint');
  10. // Check feature powerset.
  11. await $`cargo ${toolchain} hack check --manifest-path ${manifestPath} --feature-powerset --all-targets ${featuresArgs}`;