{"id":20349030,"url":"https://github.com/anirudhvarma12/wmv","last_synced_at":"2025-04-12T01:22:53.892Z","repository":{"id":74216373,"uuid":"48605420","full_name":"anirudhvarma12/wmv","owner":"anirudhvarma12","description":"WMV- Whats My Version is a maven plugin that stores version information in you jar/war file for you to retrieve it during runtime.","archived":false,"fork":false,"pushed_at":"2016-10-11T04:41:41.000Z","size":16,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-25T21:07:38.327Z","etag":null,"topics":["egit","java","maven","maven-plugin"],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/anirudhvarma12.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-12-26T09:08:19.000Z","updated_at":"2019-06-07T04:02:00.000Z","dependencies_parsed_at":null,"dependency_job_id":"96d4eeae-8aa1-4f19-9743-382d2ae57278","html_url":"https://github.com/anirudhvarma12/wmv","commit_stats":null,"previous_names":[],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anirudhvarma12%2Fwmv","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anirudhvarma12%2Fwmv/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anirudhvarma12%2Fwmv/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anirudhvarma12%2Fwmv/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/anirudhvarma12","download_url":"https://codeload.github.com/anirudhvarma12/wmv/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248502154,"owners_count":21114751,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["egit","java","maven","maven-plugin"],"created_at":"2024-11-14T22:23:52.648Z","updated_at":"2025-04-12T01:22:53.873Z","avatar_url":"https://github.com/anirudhvarma12.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Whats My Version - WMV\nWhats My Version is a maven plugin that stores the version information of the artifact inside the jar/war file during packaging. This information can later be retreived easily to be used in anyway you want(like showing to user).\n\n# Usage\nThe plugin is available through the central maven repository -  \nAdd the following to your `pom.xml` :\n```\n   \u003cplugin\u003e\n\t\t\u003cgroupId\u003ecom.github.anirudhvarma12\u003c/groupId\u003e\n    \t\u003cartifactId\u003ewmv-maven-plugin\u003c/artifactId\u003e\n    \t\u003cversion\u003e2.1.2\u003c/version\u003e\n    \t\u003cexecutions\u003e\n    \t\t\u003cexecution\u003e\n    \t\t\t\u003cgoals\u003e\n    \t\t\t\t\u003cgoal\u003egenerate-version-info\u003c/goal\u003e\n\t\t\t    \u003c/goals\u003e\n    \t\t\u003c/execution\u003e\n    \t\u003c/executions\u003e\n    \u003c/plugin\u003e\n ```\n \n## Custom file name\nYou can change the output file name from `version.properties` to something that you like:\n```\n\t\u003cexecution\u003e\n\t\t\u003cgoals\u003e\n\t\t\t\u003cgoal\u003egenerate-version-info\u003c/goal\u003e\n\t\t\u003c/goals\u003e\n\t\t\u003cconfiguration\u003e\n\t\t\t\u003cfileName\u003emyVersion.properties\u003c/fileName\u003e\n\t\t\u003c/configuration\u003e\n\t\u003c/execution\u003e\n```\n\n## Custom file type\nYou can change the output file type from `properties` (default) to `json` or `xml`\n```\n\t\u003cexecution\u003e\n\t\t\u003cgoals\u003e\n\t\t\t\u003cgoal\u003egenerate-version-info\u003c/goal\u003e\n\t\t\u003c/goals\u003e\n\t\t\u003cconfiguration\u003e\n\t\t\t\u003cfileName\u003emyVersion.properties\u003c/fileName\u003e\n\t\t\t\u003cfileType\u003ejson\u003c/fileType\u003e\u003c!-- or xml or properties --\u003e\n\t\t\u003c/configuration\u003e\n\t\u003c/execution\u003e\n```\n## Git Support\nAs of v2.1.1, WMV supports reading tags from Git for version name. To enable Git integration simply add `versionProvider` tag to the `configuration`. Eg:- \n```\n\u003cconfiguration\u003e\n\t\u003cfileName\u003emyVersion.properties\u003c/fileName\u003e\n\t\u003cfileType\u003eproperties\u003c/fileType\u003e\n\t\u003cversionProvider\u003egit\u003c/versionProvider\u003e\n\u003c/configuration\u003e\n```\n\nWMV will always read the latest git tag.\n\n\n## Retrieving info\nThe plugin is executed when you run `mvn install`, `mvn package`, `mvn compile`, it creates a `version.properties` file in the resources folder.\nThe properties looks like this - \n```\n\t#Auto generated\n\t#Wed Dec 30 00:48:15 IST 2015\n\tversion=0.0.2-SNAPSHOT\n\tdate=30-12-2015 12-48-15\n```\n\n\nXML Structure:\n\n```\n\u003cwmv\u003e\n\t\u003cversion\u003e2.1.0-SNAPSHOT\u003c/version\u003e\n\t\u003cdate\u003e21-02-2016 23-46-33\u003c/date\u003e\n\u003c/wmv\u003e\n\n```\n\nJSON Structure:\n\n```\n{\n\t\"version\": \"2.1.0-SNAPSHOT\",\n\t\"date\": \"21-02-2016 23-52-49\"\n}\n```\n\n# LICENSE\nThe MIT License (MIT), see `License` for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanirudhvarma12%2Fwmv","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fanirudhvarma12%2Fwmv","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanirudhvarma12%2Fwmv/lists"}