Git Product home page Git Product logo

Comments (5)

fhnaumann avatar fhnaumann commented on September 7, 2024 1

Thanks for your clarification. I don't know how I missed the big working-directory section in the README...

from github-action.

MikeMcC399 avatar MikeMcC399 commented on September 7, 2024

@fhnaumann

In which directory is your lockfile package-lock.json located?

from github-action.

fhnaumann avatar fhnaumann commented on September 7, 2024

Its in a subfolder under the root.

root
| - app1
| - app2
     | - package-lock.json
     | - cypress (...)

I solved it by setting working-directory: app2/, though I don't really know why this works. As far as I know working-directory does nothing for actions that use uses:, only for run: commands. Somewhere deep in your example files I found this syntax. I don't use project: at all with this as it messes with the path.

from github-action.

MikeMcC399 avatar MikeMcC399 commented on September 7, 2024

@fhnaumann

For your repo structure, with the lockfile in a sub-directory, the Cypress GitHub Action option working-directory is the correct option to use. The README documentation section working-directory describes how this works.

The Cypress GitHub Action option project expects to find a lockfile in the root of the repository. This is the reason for your original error message. The Cypress CLI documenation provides an example structure under cypress-io/cypress-test-nested-projects to demonstrate this.

Please let us know if you think that there are any errors in the documentation, otherwise I suggest to close this issue since you say that you have solved your issue by changing the workflow parameters.

from github-action.

MikeMcC399 avatar MikeMcC399 commented on September 7, 2024

@fhnaumann

Thanks for your clarification.

You're welcome! 🙂

I don't know how I missed the big working-directory section in the README...

The documentation for the project option could be improved to make it clearer. I will put that on my to-do list.

from github-action.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.