{"id":21318643,"url":"https://github.com/codaline-io/node-versionless-cache-key","last_synced_at":"2025-10-03T18:10:33.929Z","repository":{"id":59829721,"uuid":"539444251","full_name":"codaline-io/node-versionless-cache-key","owner":"codaline-io","description":"github action to retrieve a cache key for npm without the version of the package","archived":false,"fork":false,"pushed_at":"2024-04-08T08:56:14.000Z","size":304,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-02-18T05:03:02.616Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/codaline-io.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2022-09-21T11:07:03.000Z","updated_at":"2022-09-21T11:42:25.000Z","dependencies_parsed_at":"2023-01-05T04:53:16.189Z","dependency_job_id":null,"html_url":"https://github.com/codaline-io/node-versionless-cache-key","commit_stats":{"total_commits":17,"total_committers":1,"mean_commits":17.0,"dds":0.0,"last_synced_commit":"5bc8a9f940038341388d09c07d71d98295d03981"},"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codaline-io%2Fnode-versionless-cache-key","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codaline-io%2Fnode-versionless-cache-key/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codaline-io%2Fnode-versionless-cache-key/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codaline-io%2Fnode-versionless-cache-key/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codaline-io","download_url":"https://codeload.github.com/codaline-io/node-versionless-cache-key/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243796741,"owners_count":20349264,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-21T19:18:47.693Z","updated_at":"2025-10-03T18:10:28.892Z","avatar_url":"https://github.com/codaline-io.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# node-versionless-cache-key\n\nThis action generates a cache key out of the package.json and package-lock.json.\n\nThe Problem: The package-lock.json contains the package version. If that versions changes the hash of the file changes. To avoid getting a new cache key, when your package version changes this actions strips the version.\n\nIt accepts a package.json and package-lock.json file path.\nNothing special is happening. Just replacing the version in package-lock and getting a hash back.\n\n## What is happening\n\n1.   reads json files\n2.   grab package name from package.json\n3.   search for that package name and its following version key in package-lock.json\n4.   replaces all whitespaces, tabs and newlines and the version number with empty string\n5.   hashes the file content and output it as cache key\n\n## Inputs\n\n- **packageJSON**: path to package.json file. Default `./package.json`.\n- **packageLockJSON**: path to package-lock.json file. Default `./package-lock.json`.\n\n## Outputs\n\n- **cacheKey**: The generated hash over package-lock.json without version number.\n\n## Example usage\n\n```\nuses: codaline-io/node-versionless-cache-key@0.0.1\nwith:\n  packageJSON: custom-sub-folder/package-test.json\n  packageLockJSON: custom-sub-folder/my-lock-file.json\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodaline-io%2Fnode-versionless-cache-key","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodaline-io%2Fnode-versionless-cache-key","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodaline-io%2Fnode-versionless-cache-key/lists"}