
Security News
Package Maintainers Call for Improvements to GitHub’s New npm Security Plan
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
test-repository-neg4n-template
Advanced tools
An opinionated production-ready TypeScript library template with automated builds, testing, and releases.
Test
@arethetypeswrong/cli
to check package exportsinit.sh
script
Run the initialization script to automatically configure your repository:
# One-command setup
./init.sh
This script will:
The script will guide you to set up these secrets if missing:
NPM_TOKEN (for publishing):
# Generate NPM token with OTP for enhanced security
pnpm token create --otp=<YOUR_OTP> --registry=https://registry.npmjs.org/
# Set the token as repository secret
gh secret set NPM_TOKEN --body "your-npm-token-here"
ACTIONS_BRANCH_PROTECTION_BYPASS (for automated releases):
# Create Personal Access Token with 'repo' permissions
# Visit: https://github.com/settings/personal-access-tokens/new
# Set the PAT as repository secret
gh secret set ACTIONS_BRANCH_PROTECTION_BYPASS --body "your-pat-token-here"
Command | Description |
---|---|
pnpm dev | Watch mode build |
pnpm build | Production build |
pnpm build:check | Build + package validation |
pnpm test | Run tests |
pnpm test:watch | Watch mode testing |
pnpm test:coverage | Generate coverage report |
pnpm lint | Check linting and formatting |
pnpm lint:fix | Fix linting and formatting issues |
pnpm typecheck | TypeScript type checking |
pnpm release | Create release (CI only) |
typescript-library-template
sets rebase-only at both repository and main branch levels. Here's how to modify this:
For repository-wide changes:
For branch-specific changes:
[!TIP] Since
typescript-library-template
is rebase-only, you must enable other methods in repository settings before rulesets can use them.
If you're seeing this error in your CI/CD (GitHub Actions) pipeline:
[...]
ERR_PNPM_OUTDATED_LOCKFILE Cannot install with "frozen-lockfile" because pnpm-lock.yaml is not up to date with <ROOT>/package.json
[...]
This template uses --frozen-lockfile
flag to ensure consistent installations in CI/CD. The error occurs when your package.json
has been modified but the pnpm-lock.yaml
hasn't been updated to match.
Run the following command locally:
pnpm install
This will:
pnpm-lock.yaml
to match your package.json
Then commit the updated lockfile:
git add pnpm-lock.yaml
git commit -m "chore: update pnpm lockfile"
[!TIP] This is expected behavior and ensures your CI/CD uses the exact same dependency versions as your local environment.
Linear history provides several benefits for library releases:
git bisect
works more effectivelySee CONTRIBUTING.md for development workflow, commit conventions, and contribution guidelines.
The MIT License
FAQs
A neg4n's template for creating TypeScript libraries
We found that test-repository-neg4n-template demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer 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
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
Product
Socket Firewall is a free tool that blocks malicious packages at install time, giving developers proactive protection against rising supply chain attacks.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.