Github CLI v2.9.0 is out : clone labels feature #5452 is here

🙋 Intro

GitHub CLI v2.9.0 is out and brings some nice new features around labels :

Add `label clone` command

#5452

heaths


This content originally appeared on DEV Community and was authored by adriens

🙋 Intro

GitHub CLI v2.9.0 is out and brings some nice new features around labels :

Image description

As recently I felt the need (for organizational level reporting) to synchronize labels on distinct repos (see dedicated feedback) :
Image description

, this latest release was the perfect match ❣️

🎞️ The demo

A short video worths a thousand words so here go 👇

📜 Movie script

⚠️ Replace with your account⚠️

clear

# 🤔 So a new release is avilable for Gtihub Cli ❔
# 👉 What's new on v2.9.0... let's find out 👇  
gh release view v2.9.0 --repo cli/cli

# 🎁 ... and what is cli/cli #5452 "label clone" feature ❔
gh issue view 5452 --repo cli/cli

# 🆗 Let's give it a try ❣️

# 1️⃣ Create a master repo 
gh repo create gh-cli-demo-labels-master --public 

# 🏷️ See labels on the newly created repo 👇
gh label list --repo adriens/gh-cli-demo-labels-master

# ➕ Create a custom label 🦩
gh label create SOMETHING_PINK --description "I love pink things" --color FFC0CB --repo adriens/gh-cli-demo-labels-master

# ✅ And check it has been created  👇
gh label list --repo adriens/gh-cli-demo-labels-master

# 🔍 Look for the newly created label 👇
gh label list --repo adriens/gh-cli-demo-labels-master | grep PINK

# ➕  Now, create a new repo...
gh repo create gh-cli-demo-labels-synced --public 

# ... List existing labels on te newly created repo
gh label list --repo adriens/gh-cli-demo-labels-synced

# ✅ Check that the PINK label does not exists
gh label list --repo adriens/gh-cli-demo-labels-synced | grep PINK

# 🪄 Sync labels ✨
gh label clone adriens/gh-cli-demo-labels-master --repo adriens/gh-cli-demo-labels-synced

# 🕵️ See if the clone command did work 🤞
gh label list --repo adriens/gh-cli-demo-labels-synced | grep PINK

# 🎆 Job done 🤸

# 🧽 Cleanup the mess 🧼
gh repo delete adriens/gh-cli-demo-labels-master --confirm
gh repo delete adriens/gh-cli-demo-labels-synced --confirm

# 🎬 That's all folks
gh repo view cli/cli

# 🌟 Go like it 🌟
gh repo view cli/cli --web

🔖 Resources


This content originally appeared on DEV Community and was authored by adriens


Print Share Comment Cite Upload Translate Updates
APA

adriens | Sciencx (2022-04-27T19:58:11+00:00) Github CLI v2.9.0 is out : clone labels feature #5452 is here. Retrieved from https://www.scien.cx/2022/04/27/github-cli-v2-9-0-is-out-clone-labels-feature-5452-is-here/

MLA
" » Github CLI v2.9.0 is out : clone labels feature #5452 is here." adriens | Sciencx - Wednesday April 27, 2022, https://www.scien.cx/2022/04/27/github-cli-v2-9-0-is-out-clone-labels-feature-5452-is-here/
HARVARD
adriens | Sciencx Wednesday April 27, 2022 » Github CLI v2.9.0 is out : clone labels feature #5452 is here., viewed ,<https://www.scien.cx/2022/04/27/github-cli-v2-9-0-is-out-clone-labels-feature-5452-is-here/>
VANCOUVER
adriens | Sciencx - » Github CLI v2.9.0 is out : clone labels feature #5452 is here. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2022/04/27/github-cli-v2-9-0-is-out-clone-labels-feature-5452-is-here/
CHICAGO
" » Github CLI v2.9.0 is out : clone labels feature #5452 is here." adriens | Sciencx - Accessed . https://www.scien.cx/2022/04/27/github-cli-v2-9-0-is-out-clone-labels-feature-5452-is-here/
IEEE
" » Github CLI v2.9.0 is out : clone labels feature #5452 is here." adriens | Sciencx [Online]. Available: https://www.scien.cx/2022/04/27/github-cli-v2-9-0-is-out-clone-labels-feature-5452-is-here/. [Accessed: ]
rf:citation
» Github CLI v2.9.0 is out : clone labels feature #5452 is here | adriens | Sciencx | https://www.scien.cx/2022/04/27/github-cli-v2-9-0-is-out-clone-labels-feature-5452-is-here/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.