Skip to content
Snippets Groups Projects
Commit 903e72f5 authored by Miguel Angel Reina Ortega's avatar Miguel Angel Reina Ortega
Browse files

No need of token to retrieve active projects

parent 48e92c75
No related branches found
No related tags found
No related merge requests found
......@@ -6,7 +6,8 @@ NS_GITLAB_HOST=$(echo $GITLAB_HOST | cut -d'/' -f3)
echo "\n------ Getting all projects IDs --------"
# Get a list of projects in the group using GitLab API
PROJECT_IDS=$(curl --header "PRIVATE-TOKEN: $1" "$GITLAB_HOST/api/v4/groups/$SPECIFICATIONS_GROUP/projects" | grep -oP '"id":(?!'$SPECIFICATIONS_GROUP')\d+' | cut -d':' -f2)
#PROJECT_IDS=$(curl --header "PRIVATE-TOKEN: $1" "$GITLAB_HOST/api/v4/groups/$SPECIFICATIONS_GROUP/projects" | grep -oP '"id":(?!'$SPECIFICATIONS_GROUP')\d+' | cut -d':' -f2)
PROJECT_IDS=$(curl "$GITLAB_HOST/api/v4/groups/$SPECIFICATIONS_GROUP/projects" | grep -oP '"id":(?!'$SPECIFICATIONS_GROUP')\d+' | cut -d':' -f2)
echo $PROJECT_IDS
PROJECT_IDS="41" # Use TS-0019 for debugging
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment