パッケージを公開するリポジトリにセキュリティ管理について扱う
- OIDC
- Trusted Publisher
パッケージを公開するリポジトリにセキュリティ管理について扱う
#!/usr/bin/env node --experimental-strip-types | |
import { promises as fs, readFileSync } from 'node:fs'; | |
import { join } from 'node:path'; | |
import { execSync } from 'node:child_process'; | |
import { existsSync } from 'node:fs'; | |
// 1Password account configuration | |
const OP_ACCOUNT = '**********YOUR********.1password.com'; | |
// Check if 1Password CLI is available |
whois npnjs.com | |
Domain Name: NPNJS.COM | |
Registry Domain ID: 3000365290_DOMAIN_COM-VRSN | |
Registrar WHOIS Server: whois.namesilo.com | |
Registrar URL: http://www.namesilo.com | |
Updated Date: 2025-07-18T23:20:33Z | |
Creation Date: 2025-07-14T15:24:40Z | |
Registry Expiry Date: 2026-07-14T15:24:40Z | |
Registrar: NameSilo, LLC | |
Registrar IANA ID: 1479 |
#!/usr/bin/env node --experimental-strip-types | |
// # npm/yarn を pnpm に移行するスクリプト | |
// ## 制限 | |
// Node.jsのコアパッケージのみを利用する | |
// - fsのglob | |
// https://nodejs.org/api/fs.html#fspromisesglobpattern-options | |
// - util.parseArgv | |
// https://nodejs.org/api/util.html#utilparseargsconfig | |
// ## 変更箇所 |
import * as ts from "typescript"; | |
const getLineTextFromFilePosition = ( | |
file: ts.SourceFile, | |
{ line, character }: ts.LineAndCharacter, | |
): string => { | |
const lines = file.getFullText().split("\n"); | |
return lines[line]?.slice(character) ?? ""; | |
}; |
export const requireComment = { | |
meta: { | |
type: "suggestion", | |
docs: { | |
description: "useEffectにはコメントでの説明が必須です。", | |
}, | |
schema: [], | |
messages: { | |
requireCommentOnUseEffect: `useEffectにはコメントでの説明が必須です。 |