Questions tagged [nodeenv]
19 questions
1
vote
0 answers
Where should a virtual environment folder be placed relative to the main project directory?
I understand that the idea behind a virtual environment is to give your project's dependencies a local installation as opposed to a global one. I followed the steps to successfuly create and activate a virtual environment for node using nodeenv.…

TheMortiestMorty
- 421
- 2
- 4
- 12
1
vote
0 answers
next.js - dev, staging AND production config? - respecting NODE_ENV?
The way we configure all of our apps for deployment, where I work, is by using the standard pattern of a config folder with a default config and then dev/staging/prod configs that can override this.
We are then passing in env values using the…

Matthew Trow
- 2,712
- 1
- 17
- 15
1
vote
1 answer
The term 'NODE_ENV=development' is not recognized as the name of a cmdlet, function, script file, or operable program
I want to set some env variable in my node app but when I run this command NODE_ENV=development x=23 nodemon.cmd server.js then it gives me that error NODE_ENV=development' is not recognized, I found some solution where it said that I have to run…

Mohammad Ali Shuvo
- 35
- 1
- 7
1
vote
0 answers
How my NPM front end library (bundled) can detect if used in development mode or production mode?
I am author for an NPM library of browser web components and I wish to alert users that a new version has been released. Library is developed in VueJs.
Since it is not a cli, I cannot use the update-notifier package as is since the lib code is not…

Guénolé de Cadoudal
- 11
- 1
1
vote
1 answer
Jest + process.env.NODE_ENV not testing properly
I have a config file that changes a variable based on the process.env.NODE_ENV here is the function:
const { hostname } = window.location
let USE_DEV_TOOLS = false
if (
hostname === 'qa.example.com' ||
hostname === 'dev.example.com' ||
…

Jamie
- 1,909
- 3
- 22
- 47
1
vote
2 answers
Is NestJS using NODE_ENV? Is it recommended to set it?
I am using NestJS and I am new to it.
I have read that NODE_ENV is an environment variable that specifies the environment, introduced by Express.
Since NestJS is based on Express, I don't know if NODE_ENV is also relevant for NestJS.
Is it still…

Harold L. Brown
- 8,423
- 11
- 57
- 109
0
votes
1 answer
Show logs with condition on process.env.NODE_ENV
I try to show logs on my ExpressJS app only on the dev process environement.
In package.json : set NODE_ENV=dev & node index.js
My condition :
server.app.use(function(request, response, next) {
console.log(process.env.NODE_ENV, typeof…

tonymx227
- 5,293
- 16
- 48
- 91
0
votes
0 answers
Installing environment for https://github.com/igorshubovych/markdownlint-cli fails with AttributeError: 'bytes' object has no attribute 'tell' #328
I am using
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.32.2
hooks:
- id: markdownlint
Sometimes, pre-commit fails with the following error.
[INFO] Installing environment for…

Casper Lindberg
- 600
- 1
- 6
- 21
0
votes
0 answers
How to fix currently using minified code outside of NODE_ENV?
I'm not sure how to fix this and I need it for my school assignment. Help!! Pleasee!!
I did try to go on both links that were given but i cant figure out what to do.

user20960393
- 1
- 1
0
votes
0 answers
KeyError: 'arm64' in pyenv using nodeenv to install node 16.19.0
Attempting to install dependencies for the kolibri open source environment using pyenv and python virtualenv. Successfully installed python 3.9.9 and attempting to install node and yarn using nodeenv but continue running into this log for any…
0
votes
2 answers
How to specify NODE_ENV when using NodeJS CLI app
I have a CLI app made with NodeJS and I can't figure out how to specify NODE_ENV another way than specify it everytime :
NODE_ENV=development myapp
I have two env files : .env.development and .env.production
I have a config files that manage the…

WaLinke
- 726
- 2
- 6
- 25
0
votes
1 answer
Cloned project but don't have .env or ./env.local.yml to run code locally as they were in gitignore
Hi can someone provide me some help with this. I got given a node js project to work on but can't seem to run it as I dont have the .env or ./env/local.yml files. Is there a way I can run code locally without them? Is there a work around or do I…

Jo1234
- 1
- 1
0
votes
1 answer
Error: Environment Vairable name is not recognized as an internal or external command in NodeJS
I am not very experienced in Nodejs but I am trying to fetch some some information in my node app that I will pass from CMD/terminal that I will access through process.env in my app.
For example, I want to pass PORT NUMBER through env in my node and…

Dhirender
- 604
- 8
- 23
0
votes
1 answer
Heroku NODE_ENV is set for me as development instead off production
Hi from everywhere I have read about the Heroku environment variable NODE_ENV is that they set it as production for everyone but for me some odd reason it is set for me as development. How can I change it back to production?
I have even tried to…

Mohamed
- 425
- 4
- 14
0
votes
1 answer
webpack process.env.NODE_ENV undefined
I have the webpack.config below. I'm using a vue plugin (vue-fusioncharts) that's running javascript that looks for "process.env.NODE_ENV !== 'production'", and from what I can tell putting a break point there, the "process" object is null at that…

mgmedick
- 686
- 7
- 23