-
Notifications
You must be signed in to change notification settings - Fork 4
Deploying with Git Tags
Before deploying, ensure your web component meets all the requirements necessary for publication. Check out the How-to guide for a comprehensive checklist.
Web components in the Open Data Hub Community are deployed to production using git tags, which allows for precise version control. Here's how you can manage and deploy your web component using this method:
-
Verify Existing Tags
- To see all existing tags in your repository, use the following command:
git tag
- This will list all the tags currently created, helping you keep track of versions and avoid duplicates.
- To see all existing tags in your repository, use the following command:
-
Identify the Latest Tag
- To determine which commit has the latest tag, utilize the
git log
command:git log
- This command provides a detailed commit history. Tags in the log will be highlighted, allowing you to see which commit corresponds to the latest version. For instance, in the repository
webcomp-flightdata-realtime
, the tags might be displayed in bold and red for easy identification.
- To determine which commit has the latest tag, utilize the
-
Create a New Tag
- When you're ready to deploy a new version of your web component, create a new tag with a semantic versioning format:
git tag v0.0.5
- Replace
v0.0.5
with your appropriate version number.
- When you're ready to deploy a new version of your web component, create a new tag with a semantic versioning format:
-
Push the New Tag
- After creating the new tag, push it to your remote repository to update the version available in the store:
git push --tags
- This command ensures that your new version is published and available for deployment through the Open Data Hub Store.
- After creating the new tag, push it to your remote repository to update the version available in the store:
By following these steps, you can maintain control over your web component’s versioning and ensure a smooth deployment process.
For repositories other than web components, the standard deployment method involves using the production branch. Ensure you merge your changes into the prod
branch to deploy updates.
Here's an example to illustrate these steps. Suppose you have a web component named webcomp-weather-widget
and you want to deploy a new version.
-
Check existing tags:
git tag
-
Identify the latest commit with a tag:
git log
-
Create a new tag for version 1.0.0:
git tag v1.0.0
-
Push the new tag to the repository:
git push --tags
Following these steps ensures your web component is correctly versioned and deployed.
This wiki contains additional information about the Open Data Hub alongside the Open Data Hub - Official Documentation 🔗 .