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

option --releases not working #125

Closed
rdbox opened this issue Aug 14, 2019 · 15 comments
Closed

option --releases not working #125

rdbox opened this issue Aug 14, 2019 · 15 comments

Comments

@rdbox
Copy link

rdbox commented Aug 14, 2019

great script but why doesn't it work
--releases in the folder

/root/copy-repo/repositories/jest/releases
empty although there are files and they can be downloaded

what should be done?

Log:

Backing up user gituser to /root/copy-repo
Requesting https://api.github.com/user?per_page=100&page=1
Retrieving repositories
Requesting https://api.github.com/repos/gituser/jest?per_page=100&page=1
Filtering repositories
Backing up repositories
Updating jest in /root/copy-repo/repositories/jest/repository
Skipping jest (https://*****:x-oauth-basic@github.com/gituser/jest.wiki.git) since it's not initialized
Retrieving gituser/jest issues
Requesting https://api.github.com/repos/gituser/jest/issues?filter=all&per_page=100&state=open&page=1
Requesting https://api.github.com/repos/gituser/jest/issues?filter=all&per_page=100&state=closed&page=1
Saving 0 issues to disk
Retrieving gituser/jest pull requests
Requesting https://api.github.com/repos/gituser/jest/pulls?sort=updated&direction=desc&filter=all&state=open&per_page=100&page=1
Requesting https://api.github.com/repos/gituser/jest/pulls?sort=updated&direction=desc&filter=all&state=closed&per_page=100&page=1
Saving 0 pull requests to disk
Retrieving gituser/jest milestones
Requesting https://api.github.com/repos/gituser/jest/milestones?per_page=100&state=all&page=1
Saving 0 milestones to disk
Retrieving gituser labels
Requesting https://api.github.com/repos/gituser/jest/labels?per_page=100&page=1
Writing 8 labels to disk
Retrieving gituser hooks
Requesting https://api.github.com/repos/gituser/jest/hooks?per_page=100&page=1
Writing 0 hooks to disk
Retrieving gituser/jest releases
Requesting https://api.github.com/repos/gituser/jest/releases?per_page=100&page=1
Saving 0 releases to disk
Retrieving gituser starred repositories
Requesting https://api.github.com/users/gituser/starred?per_page=100&page=1
Writing 41 starred repositories to disk
Retrieving gituser watched repositories
Requesting https://api.github.com/users/gituser/subscriptions?per_page=100&page=1
Requesting https://api.github.com/users/gituser/subscriptions?per_page=100&page=2
Writing 150 watched repositories to disk
Retrieving gituser followers
Requesting https://api.github.com/users/gituser/followers?per_page=100&page=1
Writing 1 followers to disk
Retrieving gituser following
Requesting https://api.github.com/users/gituser/following?per_page=100&page=1
Writing 3 following to disk
@josegonzalez
Copy link
Owner

For the releases flag:

'include release information, not including assets or binaries'

@josegonzalez
Copy link
Owner

I don't really maintain this package, so if something isn't working, you or others will need to file pull requests to fix it (or you could pay me to do so, but most people opt out of this).

@rdbox
Copy link
Author

rdbox commented Aug 14, 2019

@josegonzalez
good, but I really like your script convenient. The best has not found anything yet

@whwright
Copy link
Contributor

There is also the --assets flag

@rdbox
Copy link
Author

rdbox commented Aug 14, 2019

@whwright tried it does not help the releases folder is empty

@whwright
Copy link
Contributor

Do you actually have assets associated with the release? This will not include source zips.

@rdbox
Copy link
Author

rdbox commented Aug 14, 2019

@whwright

image
I thought that at least the links would be saved for downloading zip files.
But even this is not a pity (((

@rdbox
Copy link
Author

rdbox commented Aug 14, 2019

I decided to backup my repositories and fork because github has a new administration. It is not known what repositories can be in their heads, but for me this is valuable information like a diamond

@whwright
Copy link
Contributor

You are backing up a copy of the repository with this tool, AKA the source code. Downloading the source zips would be redundant. If you don't want the whole source tree, you could use the --bare option.

This is working as intended.

@rdbox
Copy link
Author

rdbox commented Aug 14, 2019

github-backup rdbox -t TOKEN -o $(pwd) --all --bare -P -F -R RancherOS
github-backup rdbox -t TOKEN -o $(pwd) --all --releases --assets -P -F -R RancherOS
folder empty

@rdbox
Copy link
Author

rdbox commented Aug 14, 2019

@whwright some kind of magic doesn't work for me

version
github-backup 0.25.0

@whwright
Copy link
Contributor

Source zips are not included. rdbox/RancherOS only has releases with the default source code. Backup a repo that has actual assets attached to a release.

$ github-backup -t ${TOKEN} rholder -R debinate --releases --assets --output-directory output
$ ls -l output/repositories/debinate/releases/debinate-0.5.0-all.deb
-rw-r--r-- 1 harrison.wright OPAD\Domain Users 5.5K Aug 15 08:04 output/repositories/debinate/releases/debinate-0.5.0-all.deb

@rdbox
Copy link
Author

rdbox commented Aug 16, 2019

@whwright
it doesn’t work for me, I did everything as you showed.

root@server:~/copy-repo# github-backup rdbox -t TOKEN --releases   --assets  -R debinate  -o $(pwd)
Backing up user rdbox to /root/copy-repo
Requesting https://api.github.com/user?per_page=100&page=1
Retrieving repositories
Requesting https://api.github.com/repos/rdbox/debinate?per_page=100&page=1
Filtering repositories
Backing up repositories
root@server:~/copy-repo# ls repositories/debinate/releases/
root@server:~/copy-repo# ls -las repositories/debinate/releases/
total 8
4 drwxr-xr-x 2 root root 4096 Aug 15 21:37 .
4 drwxr-xr-x 9 root root 4096 Aug 15 21:37 ..
root@server:~/copy-repo#

@whwright
Copy link
Contributor

It looks like forked repositories do not bring over release assets with them. You'll need to backup the original repo.

@josegonzalez
Copy link
Owner

Closing as what @whwright says is correct: https://github.com/rdbox/debinate/releases

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants