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

Use jovo-cli for building info and model outside source folder #189

Open
1 of 4 tasks
acerbisgianluca opened this issue Apr 14, 2021 · 2 comments
Open
1 of 4 tasks
Assignees
Labels
Enhancement Question/Discussion v3 Issues/PRs for v3 of the Jovo CLI

Comments

@acerbisgianluca
Copy link

I'm submitting a...

  • Bug report
  • Feature request
  • Documentation issue or request
  • Other... Please describe:

Expected Behavior

I've this folder tree:

- root
    - models/
        - it-IT.json
    - src/
        - skill/
             - app.js
             - index.js
             - config.js
             - package.json
             - src/......
    - project.js

I expect that when I run jovo build -t model (or -t info) inside the root folder, it just builds things up without having to be inside the skill folder (in this case src/skill).

I tried adding -s .\src\skill, but it has no effect.

Current Behavior

jovo build -t model throws the following error, because this function returns false:

async isInProjectDirectory(): Promise<boolean> {

Error log

To use this command, please go into the directory of a valid Jovo project.

Your Environment

  • Jovo CLI version used: 3.2.1
  • Operating System: Windows 10
@rubenaeg rubenaeg self-assigned this Apr 15, 2021
@rubenaeg
Copy link
Contributor

rubenaeg commented Apr 15, 2021

Do you mind me asking why you moved your package.json inside src/skill/? My folder structure looks like this:

- root
  - models/
  - src/
    - skill/
      - app.js
      - config.js
      - index.js
  - project.js
  - package.json

and everything works fine...

@acerbisgianluca
Copy link
Author

Oh, the only thing that I haven't tried was moving package.json back to the root folder lol

Do you mind me asking why you moved your package.json inside src/skill/?

I moved it because I've different lambda functions inside src/ and each of them has its own package.json. Also I hadn't thought that jovo-cli needed the package.json in order to run all commands. For building model and info, the only needed elements are project.js and the models folder, aren't them?

@rubenaeg rubenaeg added Enhancement Question/Discussion v3 Issues/PRs for v3 of the Jovo CLI labels Jun 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement Question/Discussion v3 Issues/PRs for v3 of the Jovo CLI
Projects
None yet
Development

No branches or pull requests

2 participants