-
Notifications
You must be signed in to change notification settings - Fork 11
[WIP] Set up environment variables #185
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
base: master
Are you sure you want to change the base?
Conversation
|
I don't think it was an intentional design choice that we have copies of
the css and other assets in both repos (gutenbergsite and autocat3). It's
just an artifact from before we started using github for revision control.
It would make a lot of sense to have that stuff only in one repo. Probably
gutenbergsite IMO since that stuff 'fits' better with the static pages
served by that repo.
Perhaps you can show us what that would look like as a submodule - i'm not
familiar with that approach. It sounds like it might make sense. It would
also be possible to set up a new repo just for the static assets (css,
image, .js & similar) that would be incorporated into gutenbergsite and
autocat3. (We would of course call it 'gutenbergassets').
A bit of work on an options analysis would be helpful for choosing the way
forward. But definitely I think we should not be needing to hand-maintain
one repos content for use by a tool from another repo.
~ Greg
…On Sat, Aug 16, 2025 at 10:39 AM Leithen ***@***.***> wrote:
Description
When working on autocat3 locally, I have a number of un-staged changes to
get the site to load similarly to dev. These include css and image files,
as well as changes to the postgres setup. This PR attempts to streamline
that workflow a bit. It does this by setting up environment variables which
can then be used to dynamically change different parts of the application.
Additional ideas
The biggest issue IMO is that the CSS/Images are not linked between
gutenbergsite <https://github.com/gutenbergtools/gutenbergsite> and
autocat3. This decoupling makes it very difficult to validate changes that
are made across both repositories. I am assuming there is a good reason for
this decoupling (though it is worth re-considering this as I don't know
what that reason is). But, based on the assumption they need to be
separate, we can still make some improvements.
We could use git submodule to link the gutenbergsite/gutenberg
<https://github.com/gutenbergtools/gutenbergsite/tree/master/gutenberg>
to the autocat3 static directory. This will allow devs to pull down recent
gutenbergsite changes to autocat3. The static directory can be removed from
the production build of the site, so it will only impact local development.
------------------------------
You can view, comment on, or merge this pull request online at:
#185
Commit Summary
- 94f20ad
<94f20ad>
set up environment variables
File Changes
(8 files <https://github.com/gutenbergtools/autocat3/pull/185/files>)
- *A* .env.example
<https://github.com/gutenbergtools/autocat3/pull/185/files#diff-a3046da0d15a27e89f2afe639b25748a7ad4d9290af3e7b1b6c1a5533c8f0a8c>
(2)
- *M* .gitignore
<https://github.com/gutenbergtools/autocat3/pull/185/files#diff-bc37d034bad564583790a46f19d807abfe519c5671395fd494d8cce506c42947>
(3)
- *M* AdvSearchPage.py
<https://github.com/gutenbergtools/autocat3/pull/185/files#diff-a54b2fed3e7d6c0d8a9d21016fe75054f00fd061e06bfb3f270a8b901ecbdaef>
(11)
- *M* BaseSearcher.py
<https://github.com/gutenbergtools/autocat3/pull/185/files#diff-d69bb55e5edb065b50f27603432f8f6cc7bbb7076894806643d3dbd36879a6a3>
(2)
- *M* CherryPy.conf
<https://github.com/gutenbergtools/autocat3/pull/185/files#diff-d0ce59fa0e79dae8f150d5a45646c3aa430020861fec63fc4be7de5eaadd6636>
(5)
- *M* Page.py
<https://github.com/gutenbergtools/autocat3/pull/185/files#diff-34b1b7e5ab490e3c57d592bca3586331c89c8fbf3ae6addafaaac0b1464f3759>
(3)
- *M* templates/menu.html
<https://github.com/gutenbergtools/autocat3/pull/185/files#diff-9f9641ec8a933174735c023b5910cbdc78e376bca6fcdc5b4d74517d0b7e8daa>
(2)
- *M* templates/site-layout.html
<https://github.com/gutenbergtools/autocat3/pull/185/files#diff-8baae5bfd5ae923148c5af89c657ed9ad2a6f2722551356ace4caa63c7b7134a>
(9)
Patch Links:
- https://github.com/gutenbergtools/autocat3/pull/185.patch
- https://github.com/gutenbergtools/autocat3/pull/185.diff
—
Reply to this email directly, view it on GitHub
<#185>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AFQRDLXGVVKXKLZIDSK454L3N5UEFAVCNFSM6AAAAACEBW252WVHI2DSMVQWIX3LMV43ASLTON2WKOZTGMZDONBYGA3TMNQ>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
|
@gbnewby Thanks for the quick feedback! I have made another PR that shows the submodule approach. You can view that here: #186. With this approach, I think there would not be any need to create a third repo. All the files would live in gutenbergsite, as they do today, and would simply be pulled into autocat3. There are still some issues with this approach, primarily that some changes will still require 2 PRs, one to each repo. This is not something a third repo would fix, and likely only fixable by merging into a single repo. I left this PR unchanged in case we want to play with other options. |
|
The reason we are needing to maintain autocat3 in parallel with gutenbergsite is that we're generating the header menus in 2 different ways. putting 2 generators in one repo doesn't fix that. Refactoring fixes that. Not hard to do. But better to do it when the header menu has settled down. |
Description
When working on autocat3 locally, I have a number of un-staged changes to get the site to load similarly to dev. These include css and image files, as well as changes to the postgres setup. This PR attempts to streamline that workflow a bit. It does this by setting up environment variables which can then be used to dynamically change different parts of the application.
Additional ideas
The biggest issue IMO is that the CSS/Images are not linked between gutenbergsite and autocat3. This decoupling makes it very difficult to validate changes that are made across both repositories. I am assuming there is a good reason for this decoupling (though it is worth re-considering this as I don't know what that reason is). But, based on the assumption they need to be separate, we can still make some improvements.
We could use
git submoduleto link the gutenbergsite/gutenberg to the autocat3 static directory. This will allow devs to pull down recent gutenbergsite changes to autocat3. The static directory can be removed from the production build of the site, so it will only impact local development.