Hi,

A solution is to use GitLab APIs through curl.
It can be edited a visibility_level of a project.

  See here <https://docs.gitlab.com/ce/api/projects.html#edit-project>.

  visibility_level is gitlab's property, not git's.



By the way, how about a different solution such that:

 (1) make a public group, where your projects are public,
 (2) fork a project to a different namespace (maybe your username),
 (3) do some work on the forked project, which is private,
 (4) make a merge request from the forked project to the public one,
 (5) accept the merge request in the public project.

So you can maintain the project privately, without loss of public
availability of a released project.


Regards

--
Lemures Lemniscati


==
Subject: How to change a project visibility from the CLI?
Date: Sun, 9 Oct 2016 07:26:20 -0700 (PDT)
From: jean-christophe manciot <actionmysti...@gmail.com>

> Hi guys,
> 
> I know we can change any project visibility from the browser as explained 
> here <https://docs.gitlab.com/ce/public_access/public_access.html>, but is 
> there any corresponding way with a git command?
> The use case is to lock public access to a project while it is updated 
> online with a script by making it private, and then changing it back to 
> public when the maintenance is done.
> 
> I maintain multiple projects on Gitlab here 
> <https://gitlab.com/u/jean-christophe-manciot/projects>.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "GitLab" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to gitlabhq+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/gitlabhq/24652d8b-9d26-40b6-b2dd-43f6a8cee046%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"GitLab" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to gitlabhq+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/gitlabhq/20161010094757.C992.50F79699%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to