it's working
This commit is contained in:
parent
5415d10f56
commit
b9edfd2e61
|
@ -4,14 +4,14 @@ REPO_NAME=$(basename $(pwd))
|
||||||
GITEA_USERNAME=aynish
|
GITEA_USERNAME=aynish
|
||||||
CREATE_REPO=true
|
CREATE_REPO=true
|
||||||
|
|
||||||
curl -X POST -H "Content-Type: application/json" -d "{ \"name\": \"${REPO_NAME}\"}" \
|
curl -X 'POST' -H "Content-Type: application/json" -d "{ \"name\": \"${REPO_NAME}\"}" \
|
||||||
-H "Authorization: token ${GITEA_TOKEN}" \
|
-H "Authorization: token ${GITEA_TOKEN}" \
|
||||||
"https://git.sealight.xyz/api/v1/user/repo"
|
"https://git.sealight.xyz/api/v1/user/repos"
|
||||||
|
|
||||||
if [ ${CREATE_REPO} ]; then
|
if [ ${CREATE_REPO} ]; then
|
||||||
git init
|
git init
|
||||||
git add .
|
git add .
|
||||||
git commit -m "Initial Commit"
|
git commit -m "Initial Commit"
|
||||||
git remote add "gitea@git.sealight.xyz:${GITEA_USERNAME}/${REPO_NAME}.git"
|
git remote add origin "gitea@git.sealight.xyz:${GITEA_USERNAME}/${REPO_NAME}.git"
|
||||||
git push
|
git push
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in a new issue