arethetypeswrong / arethetypeswrong/arethetypeswrong.github.io
Support Running Without Triggering npm pack | postbuild support
- Langage dominant
- TypeScript
- Étoiles
- 1.6k
- Forks
- 65
- Métriques de merge des PR
- Aucune PR mergée en 30 j
Description
# Description:
It would be helpful to allow the tool to run directly on the current folder without automatically triggering `npm pack`.
# Use Case:
I want to use this tool as part of a `postbuild` script. However, the current behavior causes an infinite loop:
- `npm postbuild` triggers `attw`
- `attw` triggers `npm pack`
- `npm pack` triggers `npm build`
- `npm build` triggers `npm postbuild`
- ...and the cycle **repeats**
# Current Workaround:
To avoid this loop, I manually create a tarball and run `attw` on it:
```
"postbuild": "tar -czf dist/archive.tgz LICENSE README.md dist/cjs dist/esm dist/umd docs package.json && npx attw --format ascii dist/archive.tgz && rm dist/archive.tgz"
```
# Proposed Solution:
Introduce an option or flag to allow `attw` to operate directly on the current directory without invoking `npm pack`.
Guide de contribution
Aucun guide de contribution indexé pour ce dépôt
Piste de recherche
Commencez par localiser le chemin de la CLI attw qui invoque npm pack et examinez comment les options de ligne de commande sont analysées. La modification est terminée lorsque attw peut analyser le répertoire courant sans invoquer npm pack, afin de pouvoir s’exécuter depuis un script postbuild sans déclencher la boucle de build.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- node.js, typescript
- Domaine
- build-system, cli
- Type d'issue
- Fonctionnalité
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 42/100