![Maven Central Adds Sigstore Signature Validation](https://cdn.sanity.io/images/cgdhsj6q/production/7da3bc8a946cfb5df15d7fcf49767faedc72b483-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Maven Central Adds Sigstore Signature Validation
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
@sketch-hq/sketch-assistant-cli
Advanced tools
Sketch Assistants Node command-line utility.
You can use this utility to run Assistants against Sketch files outside of Sketch.
It can run whichever Assistants have been added to the file by Sketch, or run a custom set of Assistants passed in on the command line.
npm i -g @sketch-hq/sketch-assistant-cli
Or,
yarn global add @sketch-hq/sketch-assistant-cli
The sketch-assistants
command will then be available. See below for usage instructions.
Alternatively the CLI will work when installed locally to a project too.
yarn add @sketch-hq/sketch-assistant-cli
The sketch-assistants
command will then be available to use in your package.json
scripts.
## Local development
Setup the monorepo according to the Getting Started instructions, and then in this folder:
yarn build
./bin/cli.js <args>
Run a Sketch file's configured Assistants.
sketch-assistants "./path/to/file.sketch"
Run multiple files:
sketch-assistants "./path/to/file-1.sketch" "./path/to/file-2.sketch"
Or use globs to run all Sketch files that match a pattern:
sketch-assistants "./**/*.sketch"
--json
Switch from human-readable output to JSON. Example:
sketch-assistants --json "./path/to/file.sketch"
--clear-cache
When Assistants are installed before a run, they are cached in a temporary folder to make future runs faster. Pass this flag to delete the cache folder.
--profile
Output statistics instead of results.
--workspace
Optionally supply and overwrite the Assistant workspace configuration within the Sketch file(s) with your own. This can be useful for running Assistants against a file that haven't yet been setup with Assistants in the Sketch app.
sketch-assistants --workspace=./workspace.json "./path/to/file.sketch"
The data shape of the workspace itself is essentially a package.json, with the dependencies section indicating the active Assistants. The workspace JSON example below activates two Assistants:
{
"dependencies": {
"@sketch-hq/sketch-tidy-assistant": "latest",
"@sketch-hq/sketch-naming-conventions-assistant": "latest"
}
}
--assistant
Optionally supply a custom Assistant to use on the files. This is an Assistant defined entirely in JSON. Assistants to extend, as well as a custom configuration of object can be supplied.
sketch-assistants --assistant=./assistant.json "./path/to/file.sketch"
Example Assistant definition in JSON:
{
"name": "max-3",
"dependencies": {
"@sketch-hq/sketch-core-assistant": "latest"
},
"assistant": {
"extends": ["@sketch-hq/sketch-core-assistant"],
"config": {
"rules": {
"@sketch-hq/sketch-core-assistant/groups-max-layers": {
"active": true,
"maxLayers": 3,
"skipClasses": []
}
}
}
}
}
FAQs
Sketch Assistants Node command-line utility.
The npm package @sketch-hq/sketch-assistant-cli receives a total of 0 weekly downloads. As such, @sketch-hq/sketch-assistant-cli popularity was classified as not popular.
We found that @sketch-hq/sketch-assistant-cli demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
Security News
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.