A.khaled
A.khaled

Reputation: 545

How to share a project from private github repository?

I have been working on a project and uploaded it on github. Now I want to apply for an internship and put the project in my resume. The problem is that the repo is private so I can not share it. Is there any sufficient way to share this project in my repo ? And if not, what are the git sites which provide shareable links in order to avoid this problem in the furure? Thanks in advance.

Upvotes: 13

Views: 36825

Answers (4)

Hadi
Hadi

Reputation: 120

if you want to share some part of your project and keep another part private, you can make multiple repositories for each part, then choose public and private as you wish. so make the main project private and add your part to it as a "submodule".

git submodule add "address of your project part"

now you can share each one of your projects with anyone you want.

if you want to read more about submodule read this article:

https://github.blog/2016-02-01-working-with-submodules/

Upvotes: 1

Carlos Martins
Carlos Martins

Reputation: 53

In your case I would just make the repo public... no one is gonna steal your project. You want people to see you project, so they find out that you are a great coder. Making the project public will mean that people can find it when serching on github or the web.

It will also be easyer to shate the project in social media and in your resume.

Note: a "hiden link" as sudgeste in other answares is not a serius security measure your in essence making ther project publick as web crowlers can find out the link anyway.

Upvotes: -2

Marcelo Gazzola
Marcelo Gazzola

Reputation: 1083

Go to Settings/Manage Access/Invite Colaborator

enter image description here

Upvotes: 15

teobais
teobais

Reputation: 2966

The private repos have a purpose which normally is to prohibit the public from accessing your source code. This means either as a company or as an individual you have a very serious reason you don't want to share. That said, github only provides these two options (public/private repo). Specifically, for your case, what could work is inviting other members to be collaborators on that project by just giving them read rights (when you invite somebody as a collaborator you basically have two options: a) make them collaborators, which means they have read rights, b) make them owners of the repo, which means they have read write access).

My suggestion here is you should better upload this project in the cloud or in a web ide, make it accessible only for the people who have the link and share with them the link.

Upvotes: 3

Related Questions