plone / plone/plonecli

theme_barceloneta wrong Gruntfile.js base path

Open
#46 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
20
Forks
12
PR merge metrics
No merged PRs in 30d

Description

  • Plone CLI version: 1.0
  • Python version: 2.7.16
  • Operating System: ArchLinux
Description

Adding a theme_barceloneta to my Plone add-on will generate a Gruntfile.js with the wrong setBase

What I Did
$ pip instal plonecli
$ plonecli create addon my.theme
$ cd my.theme
$ plonecli add theme_barceloneta
$ cd src/my/theme
$ npm install
$ cd theme
$ npm install
$ cd ../
$ grunt
>> Error: ENOENT: no such file or directory, chdir '/workspace/plone/src/my.theme/src/my/theme' -> 'src/my/theme/theme'

$ cat Gruntfile.js | grep setBase
grunt.file.setBase('./src/my/theme/theme');

It should be Gruntfile.js relative:

grunt.file.setBase('./theme');

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing the theme_barceloneta generation used by plonecli add theme_barceloneta and inspect the generated Gruntfile.js setBase value. Regenerate the theme and run the documented npm and grunt commands; done means the path is relative to Gruntfile.js as ./theme and grunt no longer fails with ENOENT.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, python
Domain
cli, tooling
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.