Skip to content

Commit 7db5618

Browse files
bash script
1 parent 62db9c5 commit 7db5618

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

create_repository_in_github.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
# GH_TOKEN --> will be passed from workflow as an env variable
3+
# GH_TOKEN --> will be passed from the workflow as an env variable
44
ORGANIZATION=$1
55
REPOSITORY_NAME=$2
66
REPOSITORY_DESCRIPTION=$3
@@ -18,4 +18,4 @@ curl -L \
1818
-H "Authorization: Bearer $GH_TOKEN" \
1919
-H "X-GitHub-Api-Version: 2022-11-28" \
2020
https://api.github.com/orgs/$ORGANIZATION/repos \
21-
-d '{"name":"'$REPOSITORY_NAME'","description":"'$REPOSITORY_DESCRIPTION'","homepage":"https://github.com/'$ORGANIZATION/$REPOSITORY_NAME'","private":'"$PRIVATE"',"has_issues":'"$HAS_ISSUES"',"visibility":"'$VISIBILITY'","has_projects":'"$HAS_PROJECTS"',"has_wiki":'"$HAS_WIKI"',"gitignore_template":"'$GITIGNORE_TEMPLATE'","license_template":"'$LICENSE_TEMPLATE'"}'
21+
-d "{\"name\":\"$REPOSITORY_NAME\",\"description\":\"$REPOSITORY_DESCRIPTION\",\"homepage\":\"https://github.com/$ORGANIZATION/$REPOSITORY_NAME\",\"private\":$PRIVATE,\"has_issues\":$HAS_ISSUES,\"visibility\":\"$VISIBILITY\",\"has_projects\":$HAS_PROJECTS,\"has_wiki\":$HAS_WIKI,\"gitignore_template\":\"$GITIGNORE_TEMPLATE\",\"license_template\":\"$LICENSE_TEMPLATE\"}"

0 commit comments

Comments
 (0)