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

make markdown root folder configurable #15

Merged
merged 1 commit into from
Feb 4, 2025
Merged

Conversation

PrajwolAmatya
Copy link
Collaborator

@PrajwolAmatya PrajwolAmatya commented Jan 31, 2025

Description

With this PR the markdown root folder can be made configurable. Previously all the presentation markdown files were supposed to be inside the markdown directory.
With the addition of new env PRESENTATIONS_ROOT, the root folder for all the presentation markdown files can be configured.

Usage:

  1. make copy of .env.example and name it .env
  2. set the value of PRESENTATIONS_ROOT=<markdown-directory-path>

The folder structure will be as below:

<repo-name>
└── PRESENTATIONS_ROOT
    ├── new-presentation
    │   ├── new-presentation.md
    │   ├── new-presentation-image-01.png
    │   └ ...      
    ├── demo
    │   ├── demo.md
    │   ├── demo-image-01.png
    │   └ ...      
    └ ...
    └ config.yml

Added env on training repo as well: https://github.com/opf/training/pull/138

Related WP:
https://community.openproject.org/projects/revealjs/work_packages/60523/activity

@PrajwolAmatya PrajwolAmatya self-assigned this Feb 3, 2025
@PrajwolAmatya PrajwolAmatya marked this pull request as ready for review February 3, 2025 07:09
@@ -39,6 +39,7 @@
"devDependencies": {
"browserify": "^17.0.0",
"decktape": "^3.14.0",
"dotenv": "^16.4.7",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

node should have a process object to get envs from
process.env.PRESENTATIONS_ROOT

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For this the env should be exported. IMO, it would be better to read from .env file directly rather than exporting the variable.

Copy link
Collaborator

@individual-it individual-it left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where will this setting be documented?

@PrajwolAmatya
Copy link
Collaborator Author

Where will this setting be documented?

I have updated the docs. 👍

gulpfile.js Outdated Show resolved Hide resolved
@PrajwolAmatya PrajwolAmatya merged commit 8f80f8e into main Feb 4, 2025
3 checks passed
@PrajwolAmatya PrajwolAmatya deleted the configure-root-folder branch February 4, 2025 09:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants