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

hlx up without config should render with helix-pages code #929

Closed
1 task
tripodsan opened this issue May 27, 2019 · 3 comments · Fixed by #946
Closed
1 task

hlx up without config should render with helix-pages code #929

tripodsan opened this issue May 27, 2019 · 3 comments · Fixed by #946
Assignees
Labels
enhancement New feature or request released

Comments

@tripodsan
Copy link
Contributor

tripodsan commented May 27, 2019

when running hlx up with no helix-config.yaml nor a src directory, the project should render using the fallback code from https://github.com/adobe/helix-pages.

The code should be provided via an npm package, so that it is stable in respect to semver when installing helix-cli, but also allows to update if needed. alternatively, hlx up could automatically download the code from github.

Suggestion

- [ ] create a `@adobe/helix-pages` npm package that contains the `src` and `htdocs` folder. - [ ] add `@adobe/helix-pages` as `dependency` to `helix-cli` - [ ] `hlx up` will check if a fallback code repository is needed, and if so, it will ensure that the packaged code is used for rendering. eg: 1. set the `code` and `static` repository to `${hlx-cli-installpath}/node_modules/@adobe/helix-pages` 2. set the source directory to `${hlx-cli-installpath}/node_modules/@adobe/helix-pages/src`
  • hlx up will check if a fallback code repository is needed, and if so, it will ensure that the
    helix-pages repository is checked out to .hlx/pages/master and the code is used for rendering. eg:
    1. set the static repository to .hlx/pages/master
    2. set the source directory to .hlx/pages/master/src
@tripodsan
Copy link
Contributor Author

In a discussion with @davidnuescheler we thought that it might be better and more transparent to checkout the helix-pages repo into the .hlx/pages directory. this allows for easy retrieval of the latest code.

@tripodsan
Copy link
Contributor Author

the current helix pages tries to include a header and footer md. running this on an empty projects shows ugly errors:

$ hlx up
    __ __    ___       ___
   / // /__ / (_)_ __ / _ \___ ____ ____ ___
  / _  / -_) / /\ \ // ___/ _ `/ _ `/ -_|_-<
 /_//_/\__/_/_//_\_\/_/   \_,_/\_, /\__/___/
                              /___/ v4.0.6

Checking out sources from https://github.com/adobe/helix-pages.git#master
Debugger listening on ws://127.0.0.1:9229/52db01ac-d13f-43df-959e-6f5ca6201f94
For help, see: https://nodejs.org/en/docs/inspector
Building project files...done 1081ms
[hlx] info: Starting helix-simulator v2.12.11
[hlx] info: Local Helix Dev server up and running: http://localhost:3000/
[git] info: [98433] HTTP: listening on port 57091
[hlx] error: Could not find Markdown at http://127.0.0.1:57091/raw/helix/localhost--local--default/master/header.md
[hlx] error: Could not find Markdown at http://127.0.0.1:57091/raw/helix/localhost--local--default/master/footer.md
[hlx] error: Resource not found: /header.plain.html
[hlx] error: Resource not found: /footer.plain.html

trieloff pushed a commit that referenced this issue Jun 6, 2019
# [4.1.0](v4.0.9...v4.1.0) (2019-06-06)

### Features

* **up:** checkout and use helix-pages if no source scripts are present ([#946](#946)) ([066e90b](066e90b)), closes [#929](#929)
@adobe-bot
Copy link
Collaborator

🎉 This issue has been resolved in version 4.1.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request released
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants