mirror of
https://github.com/darksaid98/auto-changelog.git
synced 2026-12-03 14:38:47 +00:00
refactor: improve changelog logic (#197)
* refactor: improve changelog logic Signed-off-by: Ardalan Amini <[email protected]> * chore: update license comment formatting across all files Replaced `/*` with `/**` for correct JSDoc-style license comments in all files. This ensures consistency and compatibility with documentation tools that rely on JSDoc conventions. Signed-off-by: Ardalan Amini <[email protected]> * test: add unit tests for inputs Signed-off-by: Ardalan Amini <[email protected]> * test: add unit tests for utils Signed-off-by: Ardalan Amini <[email protected]> * test: add unit tests for outputs Signed-off-by: Ardalan Amini <[email protected]> * test: add unit tests for nodes Signed-off-by: Ardalan Amini <[email protected]> * test: add missing unit tests Signed-off-by: Ardalan Amini <[email protected]> * chore: address PR comments Signed-off-by: Ardalan Amini <[email protected]> * chore: address PR comments Signed-off-by: Ardalan Amini <[email protected]> --------- Signed-off-by: Ardalan Amini <[email protected]>
This commit is contained in:
1 parent
3c1177539c
commit
9bd6b8698c
95 files changed
+4381
-302
No files matched your search
+5
-21
@@ -1,4 +1,4 @@
|
||||
/*
|
||||
/**
|
||||
* MIT License
|
||||
*
|
||||
* Copyright (c) 2020-2025 Ardalan Amini
|
||||
@@ -20,27 +20,11 @@
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
* SOFTWARE.
|
||||
*
|
||||
*/
|
||||
|
||||
/* istanbul ignore file */
|
||||
|
||||
import { setFailed } from "@actions/core";
|
||||
import { generateChangelog } from "./changelog.js";
|
||||
import { generateFooter } from "./footer.js";
|
||||
import { getTagInfo } from "./tag.js";
|
||||
import { setChangelog, setPrerelease, setReleaseId } from "./utils/index.js";
|
||||
import { generate } from "./generate.js";
|
||||
|
||||
async function run(): Promise<void> {
|
||||
const { prerelease, releaseId, previous } = await getTagInfo();
|
||||
|
||||
setPrerelease(prerelease);
|
||||
|
||||
setReleaseId(releaseId);
|
||||
|
||||
let changelog = await generateChangelog(previous?.sha);
|
||||
|
||||
changelog += await generateFooter(previous?.name);
|
||||
|
||||
setChangelog(changelog);
|
||||
}
|
||||
|
||||
run().catch(setFailed);
|
||||
generate().catch(setFailed);
|
||||
Reference in new issue
Block a user