Support for variables #374
mike-solomon
started this conversation in
Feature Requests
Replies: 2 comments 1 reply
-
This would be incredibly helpful 🙏🏻 |
Beta Was this translation helpful? Give feedback.
1 reply
-
I would very much like to use unix time stamp. In the case of Discord, it can be used through time stamp style. Of course, some documents may be sufficient for the last edit time to appear at the end of the document, but others may not. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Context
One feature I really wish GitBook would support is variables. We have a variety of guides that include code snippets that specify versions of various libraries. It is a pretty huge pain trying to keep those versions up-to-date so that people coming to the docs don't have to figure out what the current versions are. It's possible people may end up in a state where their code is broken because we were late in updating some of these versions. Trying to do a search and replace is often impossible as many libraries have similar version numbers.
Desired outcome
Ideally, I would be able to define some variable such as
$VERSION_REWRITE_SPRING
and a value for it such as5.1.11
. Then, I could use this variable throughout many docs. When the version changes, I would only need to update the variable file rather than every doc. I could, theoretically, even make some automation to connect to GitHub to detect the latest release and automatically update this file (which would then update all of my docs).It would be even more lovely if GitBook offered this functionality where I could point to a repository and it could keep the versions up-to-date by looking at the releases.
What's the impact of this for you?
We currently have thousands of docs in our GitBook site. This is ramping up quickly over time and the site is becoming harder to maintain because we have no way of automating updates throughout. Versions and code blocks are core to our docs.
Related issue
I found an open issue about snippets that is somewhat similar to this. It's not quite the same, but I felt like it was worth linking to.
Beta Was this translation helpful? Give feedback.
All reactions