mirror of
https://github.com/ivuorinen/actions.git
synced 2026-02-08 15:45:15 +00:00
feat: add few first actions and workflows
This commit is contained in:
31
set-git-config/action.yml
Normal file
31
set-git-config/action.yml
Normal file
@@ -0,0 +1,31 @@
|
||||
name: set-git-config
|
||||
description: "Sets git config for the action"
|
||||
|
||||
branding:
|
||||
icon: settings
|
||||
color: gray-dark
|
||||
|
||||
inputs:
|
||||
token:
|
||||
description: "GitHub token"
|
||||
required: true
|
||||
username:
|
||||
description: "GitHub username action should use"
|
||||
default: "github-actions"
|
||||
format: string
|
||||
email:
|
||||
description: "GitHub email action should use"
|
||||
default: "github-actions@github.com"
|
||||
format: email
|
||||
|
||||
runs:
|
||||
using: composite
|
||||
steps:
|
||||
- name: Set git config
|
||||
run: |
|
||||
git config --local --unset-all http.https://github.com/.extraheader || true
|
||||
git config --global --add url.https://x-access-token:${{ inputs.token }}@github.com/.insteadOf 'https://github.com/'
|
||||
git config --global --add url.https://x-access-token:${{ inputs.token }}@github.com/.insteadOf 'git@github.com:'
|
||||
git config --global user.name ${{ inputs.username }}
|
||||
git config --global user.email ${{ inputs.email }}
|
||||
shell: bash
|
||||
Reference in New Issue
Block a user