Versioning your Laravel Project
Create a string which pulls information from your Git history
Last updated
Create a string which pulls information from your Git history
Last updated
Using Git for version control, we can tag releases and then pull that tag information into our project so that it can be displayed to users. This can be helpful where you have multiple deployments of the same code base and need to be sure which version a site is running.
The above gives our config a version
element that we can then include within views, emails, support logs etc.
The config elements are accessed as {{config('version.string')}}
for example. Caching config avoids the exec functions being called on every request for the version information.
Using the github Desktop client, right click the commit and add the tag.
Using github on the web;
Using Bitbucket. In the Commits view, click on the latest commit and select tag from the sidebar;