https://github.com/friendlyanon/fetch-core-count
Make the logical CPU core count available in jobs
https://github.com/friendlyanon/fetch-core-count
Last synced: 5 months ago
JSON representation
Make the logical CPU core count available in jobs
- Host: GitHub
- URL: https://github.com/friendlyanon/fetch-core-count
- Owner: friendlyanon
- License: mit
- Created: 2020-09-27T22:50:56.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-09-27T22:53:02.000Z (over 5 years ago)
- Last Synced: 2025-08-21T23:26:12.504Z (5 months ago)
- Language: JavaScript
- Size: 1.95 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Fetch CPU core count [![CI build][1]][2]
This is a GitHub action that makes the logical CPU core count on the action
runner available for jobs.
## Outputs
### `count`
Logical core count.
This is not the same as physical core count.
### `plus_one`
`count` plus one.
### `plus_two`
`count` plus two.
## Example usage
- uses: friendlyanon/fetch-core-count@v1
id: cores
- name: Run CMake with optimal job count
run: cmake --build build -j ${{ steps.cores.outputs.plus_one }}
# License
[MIT License](LICENSE)
[1]: https://github.com/friendlyanon/fetch-core-count/workflows/CI/badge.svg
[2]: https://github.com/friendlyanon/fetch-core-count/actions?query=workflow%3ACI+branch%3Amaster