Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Script to edit a gitlab file #110

Open
emepetres opened this issue Jun 11, 2018 · 1 comment

Comments

@emepetres
Copy link
Member

commented Jun 11, 2018

Following #102, build python script that will:

1.- Receive the username, the parent gitlab repository (the original repository) and the file name to be edited.
2.- Check if the repository exists for this user in gitlab
2.1.- If the repository does not exists, fork it from the parent repository to the user space.
3.- Return a url to edit the file in the user repository.

@ncde

This comment has been minimized.

Copy link

commented Jul 20, 2018

Hello,
I wrote the following script that takes a remote repository url, username and folder name
if the folder name already exists it assumes the remote repository was cloned previously
otherwise clones it

then it checks if a branch with students/user_name exists if yes checks out to that branch
otherwise creates a new branch

the file that needs to be edited is now in the folder_name/file

the example uses the python package gitpython

script_javier.py.gz

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.