title: Deploying my project in netlify but "build.command" failed to fix
body: <pre><code>2:47:42 PM: Build ready to start
  2:47:44 PM: build-image version: 122b31996ccaffd45d820a452d6227f8312110cc (focal)
  2:47:44 PM: build-image tag: v4.5.3
  2:47:44 PM: buildbot version: 7eafb394e33f42f945c880ce4ac17c149867813a
  2:47:44 PM: Building without cache
  2:47:44 PM: Starting to prepare the repo for build
  2:47:45 PM: No cached dependencies found. Cloning fresh repo
  2:47:45 PM: git clone https://github.com/BhautikInfyOm/InfySocial-App
  2:47:47 PM: Preparing Git Reference refs/heads/main
  2:47:49 PM: Parsing package.json dependencies
  2:47:50 PM: Different publish path detected, going to use the one specified in the Netlify configuration file: 'frontend/build' versus 'build' in the Netlify UI
  2:47:50 PM: Starting build script
  2:47:50 PM: Installing dependencies
  2:47:50 PM: Python version set to 2.7
  2:47:51 PM: Downloading and installing node v16.14.1...
  2:47:51 PM: Downloading https://nodejs.org/dist/v16.14.1/node-v16.14.1-linux-x64.tar.xz...
  2:47:52 PM: Computing checksum with sha256sum
  2:47:52 PM: Checksums matched!
  2:47:57 PM: Now using node v16.14.1 (npm v8.5.0)
  2:47:57 PM: Started restoring cached build plugins
  2:47:57 PM: Finished restoring cached build plugins
  2:47:57 PM: Attempting ruby version 2.7.2, read from environment
  2:47:58 PM: Using ruby version 2.7.2
  2:47:58 PM: Using PHP version 8.0
  2:47:58 PM: Started restoring cached node modules
  2:47:58 PM: Finished restoring cached node modules
  2:47:58 PM: Installing NPM modules using NPM version 8.5.0
  2:48:00 PM: npm WARN EBADENGINE Unsupported engine {
  2:48:00 PM: npm WARN EBADENGINE   package: 'react-loader-spinner@6.0.0-0',
  2:48:00 PM: npm WARN EBADENGINE   required: { npm: 'please-use-yarn', yarn: '&gt;= 1.19.1' },
  2:48:00 PM: npm WARN EBADENGINE   current: { node: 'v16.14.1', npm: '8.5.0' }
  2:48:00 PM: npm WARN EBADENGINE }
  2:48:11 PM: npm WARN deprecated source-map-resolve@0.6.0: See https://github.com/lydell/source-map-resolve#deprecated
  2:48:19 PM: npm WARN deprecated svgo@1.3.2: This SVGO version is no longer supported. Upgrade to v2.x.x.
  2:48:32 PM: added 1464 packages, and audited 1465 packages in 33s
  2:48:32 PM: 173 packages are looking for funding
  2:48:32 PM:   run `npm fund` for details
  2:48:32 PM: 6 moderate severity vulnerabilities
  2:48:32 PM: To address all issues (including breaking changes), run:
  2:48:32 PM:   npm audit fix --force
  2:48:32 PM: Run `npm audit` for details.
  2:48:32 PM: NPM modules installed
  2:48:32 PM: Started restoring cached go cache
  2:48:32 PM: Finished restoring cached go cache
  2:48:32 PM: go version go1.16.5 linux/amd64
  2:48:32 PM: go version go1.16.5 linux/amd64
  2:48:32 PM: Installing missing commands
  2:48:32 PM: Verify run directory
  2:48:33 PM: ​
  2:48:33 PM: ────────────────────────────────────────────────────────────────
  2:48:33 PM:   Netlify Build                                                 
  2:48:33 PM: ────────────────────────────────────────────────────────────────
  2:48:33 PM: ​
  2:48:33 PM: ❯ Version
  2:48:33 PM:   @netlify/build 26.4.0
  2:48:33 PM: ​
  2:48:33 PM: ❯ Flags
  2:48:33 PM:   baseRelDir: true
  2:48:33 PM:   buildId: 6231ab3673a7c73469d33e7d
  2:48:33 PM:   deployId: 6231ab3673a7c73469d33e7f
  2:48:33 PM: ​
  2:48:33 PM: ❯ Current directory
  2:48:33 PM:   /opt/build/repo/frontend
  2:48:33 PM: ​
  2:48:33 PM: ❯ Config file
  2:48:33 PM:   No config file was defined: using default values.
  2:48:33 PM: ​
  2:48:33 PM: ❯ Context
  2:48:33 PM:   production
  2:48:33 PM: ​
  2:48:33 PM: ────────────────────────────────────────────────────────────────
  2:48:33 PM:   1. Build command from Netlify app                             
  2:48:33 PM: ────────────────────────────────────────────────────────────────
  2:48:33 PM: ​
  2:48:33 PM: $ npm run build
  2:48:34 PM: &gt; frontend@0.1.0 build
  2:48:34 PM: &gt; react-scripts build
  2:48:35 PM: Creating an optimized production build...
  2:48:37 PM: warn - The `purge`/`content` options have changed in Tailwind CSS v3.0.
  2:48:37 PM: warn - Update your configuration file to eliminate this warning.
  2:48:37 PM: warn - https://tailwindcss.com/docs/upgrade-guide#configure-content-sources
  2:48:37 PM: warn - The `darkMode` option in your Tailwind CSS configuration is set to `false`, which now behaves the same as `media`.
  2:48:37 PM: warn - Change `darkMode` to `media` or remove it entirely.
  2:48:37 PM: warn - https://tailwindcss.com/docs/upgrade-guide#remove-dark-mode-configuration
  2:49:06 PM: 
  2:49:06 PM: Treating warnings as errors because process.env.CI = true.
  2:49:06 PM: Most CI servers set it automatically.
  2:49:06 PM: 
  2:49:06 PM: Failed to compile.
  2:49:06 PM: 
  2:49:06 PM: src/App.js
  2:49:06 PM:   Line 14:6:  React Hook useEffect has a missing dependency: 'navigate'. Either include it or remove the dependency array  react-hooks/exhaustive-deps
  2:49:06 PM: src/components/Pin.jsx
  2:49:06 PM:   Line 108:17:  Using target=&quot;_blank&quot; without rel=&quot;noreferrer&quot; (which implies rel=&quot;noopener&quot;) is a security risk in older browsers: see https://mathiasbynens.github.io/rel-noopener/#recommendations  react/jsx-no-target-blank
  2:49:06 PM: src/components/PinDetails.jsx
  2:49:06 PM:   Line 10:10:  'MdMaximize' is defined but never used                                                                              no-unused-vars
  2:49:06 PM:   Line 16:10:  'addingComment' is assigned a value but never used                                                                  no-unused-vars
  2:49:06 PM:   Line 64:6:   React Hook useEffect has a missing dependency: 'fetchPinDetails'. Either include it or remove the dependency array  react-hooks/exhaustive-deps
  2:49:06 PM: src/components/UserProfile.jsx
  2:49:06 PM:   Line 53:6:  React Hook useEffect has a missing dependency: 'activeBtn'. Either include it or remove the dependency array  react-hooks/exhaustive-deps
  2:49:06 PM: src/container/Home.jsx
  2:49:06 PM:   Line 33:6:  React Hook useEffect has a missing dependency: 'userInfo?.googleId'. Either include it or remove the dependency array  react-hooks/exhaustive-deps
  2:49:06 PM: ​
  2:49:06 PM: ────────────────────────────────────────────────────────────────
  2:49:06 PM:   &quot;build.command&quot; failed                                        
  2:49:06 PM: ────────────────────────────────────────────────────────────────
  2:49:06 PM: ​
  2:49:06 PM:   Error message
  2:49:06 PM:   Command failed with exit code 1: npm run build (https://ntl.fyi/exit-code-1)
  2:49:06 PM: ​
  2:49:06 PM:   Error location
  2:49:06 PM:   In Build command from Netlify app:
  2:49:06 PM:   npm run build
  2:49:06 PM: ​
  2:49:06 PM:   Resolved config
  2:49:06 PM:   build:
  2:49:06 PM:     base: /opt/build/repo/frontend
  2:49:06 PM:     command: npm run build
  2:49:06 PM:     commandOrigin: ui
  2:49:06 PM:     environment:
  2:49:06 PM:       - REACT_APP_GOOGLE_TOKEN
  2:49:06 PM:       - REACT_APP_SANITY_PROJECTID
  2:49:06 PM:       - REACT_APP_SANITY_TOKEN
  2:49:06 PM:     publish: /opt/build/repo/frontend/build
  2:49:06 PM:     publishOrigin: ui
  2:49:06 PM:   redirects:
  2:49:06 PM:     - from: /*
        status: 200
        to: /index.html
  Caching artifacts
  2:49:06 PM: Started saving node modules
  2:49:06 PM: Finished saving node modules
  2:49:06 PM: Started saving build plugins
  2:49:06 PM: Finished saving build plugins
  2:49:06 PM: Started saving pip cache
  2:49:06 PM: Finished saving pip cache
  2:49:06 PM: Started saving emacs cask dependencies
  2:49:06 PM: Finished saving emacs cask dependencies
  2:49:06 PM: Started saving maven dependencies
  2:49:06 PM: Finished saving maven dependencies
  2:49:06 PM: Started saving boot dependencies
  2:49:07 PM: Finished saving boot dependencies
  2:49:07 PM: Started saving rust rustup cache
  2:49:07 PM: Finished saving rust rustup cache
  2:49:07 PM: Started saving go dependencies
  2:49:07 PM: Finished saving go dependencies
  2:49:11 PM: Build failed due to a user error: Build script returned non-zero exit code: 2
  2:49:11 PM: Creating deploy upload records
  2:49:11 PM: Failing build: Failed to build site
  2:49:11 PM: Failed during stage 'building site': Build script returned non-zero exit code: 2 (https://ntl.fyi/exit-code-2)
  2:49:11 PM: Finished processing build request in 1m27.044135368s
  </code></pre>