Is it possible to add FORKS to the 'projects'?
Hi,
we use this common git forking workflow model of all
our dev's doing FORKS off the main repo.
- my fork == origin. - main repo == upstream.
when we want to merge our code, we create a pull request and it gets merged. Ok. fine.
Now, i'm trying to find out how to create a new project where I want to add our developer's forked repo's in. How can I the current account i'm using, see their (forked) repo to add?
I've logged into GH with the GH-Account i'm using to connect to GH with (ie. the GH authorization):
"AppVeyor was authorized 5 days ago for repo access to
GitHub repositories as <snip> account. Your account
authorizations.
"
.. and i can access or my collegues private GH forks.
Is there a way to see those and pick them, in AV?
Comments are currently closed for this discussion. You can start a new one.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
Support Staff 1 Posted by Feodor Fitsner on 03 Feb, 2015 04:01 AM
You can do a simple Web API app (and host it on Azure Websites for free) listening for "Fork" event from GitHub webhook and then using AppVeyor API to add new projects for those forks (here YAML comes).
When calling AppVeyor create project API (http://www.appveyor.com/docs/api/projects-builds#add-project) you can specify {owner}/{repo} to any GitHub repo. Of course, you should have rights there to add webhooks and SSH keys.
Hope that helps.
-Feodor
2 Posted by Pure Krome on 03 Feb, 2015 04:24 AM
Hm. ok - sounds complex, heavy and a bit confusing.
Lets try using the API as u suggested.
{"message":"Processing of the HTTP request resulted in an exception. Please see the HTTP response returned by the 'Response' property of this exception for details."}
(i couldn't find any more info).
So what I'm assuming is this -> hitting the api, it will
- use the Token provided and find my account. - Grab my oauth secret sauce stuff from my account because i've already done the oauth permissions thingy in AV. - create a new project for the provided git repo link.
because that GH repo is private BUT you're using my oauth secret token and stuff, it should download ok, right?
Is that the general gist?
Support Staff 3 Posted by Feodor Fitsner on 03 Feb, 2015 05:10 AM
Yeah, that's correct. Don't forget to add
Content-type
header withapplication/json
in it.4 Posted by Pure Krome on 03 Feb, 2015 05:19 AM
AH! Worked!!!
I didn't add that because of this:
i assumed it didn't need it because it's say's it's default
Ok - great - i'm in business again...
So now .. could I create an issue to make this an option in the
Add Project
section of the site? eg...Would be -really- helpful :)
Support Staff 5 Posted by Feodor Fitsner on 03 Feb, 2015 05:25 AM
Sure. If you are on Postman right now could you check if that API (with preview header) https://developer.github.com/v3/repos/#list-your-repositories will return all repos for your account that you have access to.
6 Posted by Pure Krome on 03 Feb, 2015 05:40 AM
Ok - Issue #136 created :)
Using postman, i tried to list my repo's and my private one isn't there :/
I did fork my private one from another org .. and it has some notice about other orgs and stuff and using another endpoint, etc.
Support Staff 7 Posted by Feodor Fitsner on 03 Feb, 2015 06:00 PM
Have you added "magic"
application/vnd.github.moondragon+json
accept header?8 Posted by Pure Krome on 09 Feb, 2015 03:12 AM
Nope - I didn't try that.
On a side note: I didn't notice that you can any any git repo!
So i just used that option:
git repo => my private fork
credentials: repository authentication
username: whatever;
password: whatever
and that worked :) simple!!!
Pure Krome closed this discussion on 09 Feb, 2015 03:12 AM.