Игнорируйте файл в пакете NPM, но не удаляйте его

Итак, у меня есть модуль NPM для моей компании, такой, что его использует каждый API в компании, скажем, "company-SDK".

API может работать в Windows и Linux и использует некоторые файлы на платформе.

Таким образом, у модуля есть файл с именем "config.js", который мы редактируем внутри, и он содержит все файлы, которые он использует пути. Вы можете понять, что каждая платформа имеет свой собственный "config.js".

Every user that uses the "company-SDK" just logs in into the NPM user and runs "npm install company-SDK".

The module itself has "config.js" file, that is noted in.NPMIGNORE file.

The problem is that every time I publish a new version of the "company-SDK", and the users run "npm upgrade" command, it deletes every config.js file in the module folder.

Is there any way to really ignore the file, not deleting it and not updating it?

0 ответов

Другие вопросы по тегам