{"repo":"WyriHaximus/github-action-get-previous-tag","free":true,"listed":false,"github":"https://github.com/WyriHaximus/github-action-get-previous-tag","clone":"git clone https://github.com/WyriHaximus/github-action-get-previous-tag.git","description":"Get the previous tag","language":"JavaScript","stars":196,"topics":["github-actions","github","action","git","tag","hacktoberfest"],"license":"MIT","category":"workflow-automation","readme_excerpt":"Get previous tag GitHub Action that gets the latest tag from Git Input By default, this action will fail if no tag can be found, however, it accepts a fallback tag that will be used when no tag can be found. Keep in mind that when this action is used in a workflow that has no .git directory, it will still fail, and the fallback tag isn't used. It is also accepts a pattern string to query the tags based on it. Pattern to query the tag by this can be semver ( v [0-9]. [0-9]. [0-9] ) or a simple monotonically increasing integer ( r ) and defaults to And finally it takes a workingDirectory if you need to look for a tag in an alternative path. fallback : 1.0.0 pattern : v [0-9]. [0-9]. [0-9] workingDirectory : another/path/where/a/git/repo/is/checked/out Output This action has two outputs, tag for the found tag, or the fallback. And, timestamp as a UNIX Epoch timestmap for when the tag was created, or when no tag is found, and a fallback tag has be specific is provides the timestamp of action execution. tag : 1.2.3 timestamp : 123 Example Find more examples in the examples directory. The following example works together with the WyriHaximus/github-action-next-semvers and WyriHaximus/github-action-create-milestone actions. Where it provides the previous tag from that action so it can supply a set of versions for the next action, which creates a new milestone. (This snippet has been taken from the automatic code generation of wyrihaximus/fake-php-version .) License ## Copyright 2026","default_branch":null,"files":null,"tree":[],"storefront":"/r/WyriHaximus","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/WyriHaximus/github-action-get-previous-tag/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}