Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ambiguous argument 'master' #29051

Open
1 of 4 tasks
LakeVostok opened this issue Nov 23, 2024 · 0 comments
Open
1 of 4 tasks

ambiguous argument 'master' #29051

LakeVostok opened this issue Nov 23, 2024 · 0 comments

Comments

@LakeVostok
Copy link

Current Behavior

I've created nx project via npx create-nx-workspace. CLI suggested to create github actions and connecting to nx.cloud, which I've accepted. Then I've created PR(https://github.com/LakeVostok/scale-visualizer/pull/1/files) to test CI and it's not working.

Error on the screenshot:
For me it's not obvious, what is going wrong. ci.yml was generated by nx automaticly and I didn't change something in it. Am I doing something wrong or generated ci.yml is incorrect?

Expected Behavior

I expected that the CI scripts would not crash.

GitHub Repo

https://github.com/LakeVostok/scale-visualizer/

Steps to Reproduce

1.npx create-nx-workspace (pure React with vite and gitthub actions)
2.connect to nx.cloud
3.push code to the master
4.make branch from master and pr to the master
5.CI script fails

Nx Report

The CJS build of Vite's Node API is deprecated. See https://vite.dev/guide/troubleshooting.html#vite-cjs-node-api-deprecated for more details.
 NX   Report complete - copy this into the issue template
Node           : 20.18.0
OS             : linux-x64
Native Target  : x86_64-linux
npm            : 10.8.2
nx                 : 20.1.3
@nx/js             : 20.1.3
@nx/jest           : 20.1.3
@nx/eslint         : 20.1.3
@nx/workspace      : 20.1.3
@nx/devkit         : 20.1.3
@nx/eslint-plugin  : 20.1.3
@nx/playwright     : 20.1.3
@nx/react          : 20.1.3
@nx/vite           : 20.1.3
@nx/web            : 20.1.3
@nx/webpack        : 20.1.3
typescript         : 5.5.4
---------------------------------------
Registered Plugins:
@nx/vite/plugin
@nx/eslint/plugin
@nx/playwright/plugin
@nx/jest/plugin

Failure Logs

Run npx nx affected -t lint test build e2e
    npx nx affected -t lint test build e[2](https://github.com/LakeVostok/scale-visualizer/actions/runs/11990587040/job/33428248119?pr=1#step:7:2)e
    shell: /usr/bin/bash -e {0}
    env:
      NX_BASE: 
      NX_HEAD: a1e75b828eb[3](https://github.com/LakeVostok/scale-visualizer/actions/runs/11990587040/job/33428248119?pr=1#step:7:3)64fad76daae50abda81fd36ea148

  NX   No explicit --head argument provided, but found environment variable NX_HEAD so using its value as the affected head: a1e75b828eb36[4](https://github.com/LakeVostok/scale-visualizer/actions/runs/11990587040/job/33428248119?pr=1#step:7:4)fad76daae[5](https://github.com/LakeVostok/scale-visualizer/actions/runs/11990587040/job/33428248119?pr=1#step:7:5)0abda81fd3[6](https://github.com/LakeVostok/scale-visualizer/actions/runs/11990587040/job/33428248119?pr=1#step:7:6)ea148

  The CJS build of Vite's Node API is deprecated. See https://vite.dev/guide/troubleshooting.html#vite-cjs-node-api-deprecated for more details.
  fatal: ambiguous argument 'master': unknown revision or path not in the working tree.
  Use '--' to separate paths from revisions, like this:
  'git <command> [<revision>...] -- [<file>...]'

  NX   Command failed: git diff --name-only --no-renames --relative "master" "a1e[7](https://github.com/LakeVostok/scale-visualizer/actions/runs/11990587040/job/33428248119?pr=1#step:7:8)5b[8](https://github.com/LakeVostok/scale-visualizer/actions/runs/11990587040/job/33428248119?pr=1#step:7:9)28eb364fad76daae50abda81fd36ea148"

  fatal: ambiguous argument 'master': unknown revision or path not in the working tree.
  Use '--' to separate paths from revisions, like this:
  'git <command> [<revision>...] -- [<file>...]'

  Pass --verbose to see the stacktrace.

  Error: Process completed with exit code 1.

Package Manager Version

No response

Operating System

  • macOS
  • Linux
  • Windows
  • Other (Please specify)

Additional Information

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant