semantic-release | Fully automated version management and package publishing | DevOps library
kandi X-RAY | semantic-release Summary
kandi X-RAY | semantic-release Summary
:package::rocket: Fully automated version management and package publishing
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Run the repository .
- recursive function to find maintenance branches .
- Takes an array of releases and returns a maximum version for the release .
- Fetch a branch .
- Formats the authorization url with git credentials .
- Unshifts the notes in the project .
- Logs errors and warnings
- Generate prerelease specification .
- Parse a plugin
- Get a specific reference .
semantic-release Key Features
semantic-release Examples and Code Snippets
name: "Release container"
on:
push:
branches:
- main
- next
- next-major
- alpha
- beta
jobs:
release:
environment:
name: production
url: https://github.com/${{ github.repository }}/releases/tag
# .travis.yml
cache:
directories:
- ~/.npm
script:
- npm test
stages:
- test
- name: release
if: branch = master AND type = push AND fork = false
jobs:
include:
- stage: release
language: node_js
node_js: '10.18'
language: node_js
node_js:
- 8
- 6
- 4
os:
- linux
- osx
after_success:
- npm run semantic-release
Community Discussions
Trending Discussions on semantic-release
QUESTION
I am trying to publish my releases with semantic-release. Everything has worked well but the tool so far only generated tags rather than an actual GitHub Release.
My .releaserc
...ANSWER
Answered 2022-Feb-22 at 13:40As jonrsharpe pointed out, implementing the plugin semantic-release/github fixed my problem and tags and releases are now created automatically.
QUESTION
Pretty new to Nektos/act and in general running workflows locally and cant seem to find a solution to a permissions denied error when installing Node version 16. Here is the error I am running into when I run the following:
Command:
...ANSWER
Answered 2022-Feb-11 at 07:01Appears to be a bug with the recent release. I confirm that downgrading to 0.2.24 fixed this issue.
https://github.com/nektos/act/issues/935#issuecomment-1035261208
QUESTION
I have created this Angular library that I now want to use in my other Angular apps, but I seem to have trouble with my peer dependencies. I have tried fiddling around in my App's package.json, but couldn't seem to remove any of my errors.
What I have tried (in that order) :
- Removing node_modules
- ng update
- npm update
- npm audit --fix
- npm i
- Recreating a new test app all together
Here are the errors :
...ANSWER
Answered 2022-Feb-10 at 15:05This is not the issue with peer dependencies. This is more to do with version conflict. I guess you are using npm >=7 that's why you are getting this error:-
As mentioned in the error log try the below command to fix the issue:-
QUESTION
I have this Angular library uploaded to a package registry that I created on Gitlab. I've already been able to upload my library successfully to this registry using the CI. I now want to implement semantic versionning to this library, but I'm not quite sure how to do it... The version of my library does not seem to update. Here is my current Gitlab CI config :
...ANSWER
Answered 2022-Feb-10 at 08:32The problem was that I was not triggering a release with my commit messages. Once that was sorted out, the package.json updated normally.
QUESTION
I am modifying an existing library so it can be imported in typescript. I've boiled it down to a Minimal working example
The requirements- To remain backwards compatible, the library needs to be importable with a simple
It works. So far so good.
In another typescript projectNext, I created a simple typescript project that utilizes my library.
File structure:
...
ANSWER
Answered 2022-Feb-07 at 14:05I've figured it out.
In my lib.ts
I had to change the way I export my class:
QUESTION
Here is the error log message:
[3:40:55 PM] [semantic-release] › ✖ The command "git push --dry-run --no-verify https://gitlab-ci-token:[secure]@[repository-url].git HEAD:main" failed with the error message remote: You are not allowed to upload code. fatal: unable to access 'https://gitlab-ci-token:[secure]@[repository-url]/': The requested URL returned error: 403.
I have a GITLAB_TOKEN
set up in the repository settings with all the necessary permissions, but it seems it isn't even being used:
Here is my .releaserc.json
config:
ANSWER
Answered 2022-Jan-20 at 20:45So in the end the problem was that I had to add the created GITLAB_TOKEN
access token in Settings > CI/CD > Variables
QUESTION
We're updating our release workflow to use semantic-release, and I need to be able to grab the SHA of the latest tag, create a new branch with it, build our assets, commit them to that new branch.
The action I'm using to create the branch, requires the SHA of the parent branch if you're building a branch based on something other than the branch the runs the workflow.
So I have a couple actions to determine if the release is major, minor, or patch, and then will find the latest semver tag name. But I don't know how to get the SHA of this Ref.
So far I have this:
...ANSWER
Answered 2022-Jan-11 at 05:12To answer your question:
git log -1 --format="%H" REF-NAME
REF-NAME
here could be a tag, branch, or a commit ID, any of which the command will return the commit ID.
Note though that you should be able to create a branch by just supplying the tag name without the commit ID.
QUESTION
I have a C# solution containing a single project and multiple libraries using .Net 6. I'm using conventional commits (commitlint with husky) and want to use semantic-release to deploy the latest build as a ZIP file on Github based on the commit messages.
The setup I tried for C# projects:
- Install packages
.
...ANSWER
Answered 2021-Dec-31 at 12:45You could dry-run semantic-release
before dotnet publish
to fetch the version number of the release (using the @semantic-release/exec
plugin). Then pass this fetched version number to dotnet publish
:
Add the @semantic-release/exec
plugin to your npm install
commands and adjust your .releaserc.json
file to store the next release version (for example in an environment variable):
QUESTION
What I want to do
Based on the FAQ
I want to update the package.json version number on a new release.
What I did
- Create a new empty private Github repository for an organization
temp
with a README.md and .gitignore for node - Clone the repository
- Fix the first commit message via git
rebase -i --root
and change it tofeat: initial commit
- Create a package.json with the content
ANSWER
Answered 2021-Dec-29 at 12:28Based on this issue
https://github.com/semantic-release/semantic-release/issues/1593
you also need the npm module.
npm install @semantic-release/npm -D
- add
"private": true,
to your package.json if you don't want to publish to npm - add the npm plugin to the release configuration file (the order matters)
.
QUESTION
I want to migrate all the releases from a Gitlab repository that is using semantic release to a Github repository.
I can create new releases in the new Github repository starting from the last Gitlab repository, but I don't know how to transfer all Gitlab releases to Github, is this possible?
...ANSWER
Answered 2021-Dec-13 at 09:54There is no first-party feature for this in either GitLab or GitHub (when migrating to GitHub anyhow). Scripting it would be your best bet which using the GitLab and GitHub APIs.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install semantic-release
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page