当前位置:网站首页>Python3 operating gitlab
Python3 operating gitlab
2020-11-06 22:38:00 【Leaf blade】
#coding=utf-8
import base64
# Import python-gitlab library
import gitlab
url = 'http://192.168.x.xxx'
token = 'D98-t7HJpXxwhq8qbXcJ'
# Sign in
gl = gitlab.Gitlab(url, token)
# Get the project
project = gl.projects.get('ZEP-BACKEND/ZEP-BACKEND-JAVA')
# obtain javademo/config Directory file list , Version is master
items = project.repository_tree(path='javademo', ref='master')
def get_all_files(path=None, ref='master'):
items = project.repository_tree(path=path, ref=ref)
for item in items:
if item['mode'] == '040000':
# Call recursion , Achieve directory recursive output
get_all_files(item['path'], ref)
if item['mode'] == '100644':
print("===({})===".format(item['path']))
get_all_files(path='javademo', ref='master')
版权声明
本文为[Leaf blade]所创,转载请带上原文链接,感谢
边栏推荐
- [graffiti Internet of things footprints] panoramic introduction of graffiti cloud platform
- Composition of MRAM cache
- 心理咨询app开发所具备的优点与功能
- 实验一
- How to add modules to nginx image?
- Introduction to Huawei cloud micro certification examination
- Js字符串-String字符串对象方法
- Jenkins installation and deployment process
- Stm32f030f4p6 compatible with smart micro mm32f031f4p6
- QT audio and video development 46 video transmission UDP version
猜你喜欢

谈了多年的数字化转型,为什么还有很多企业依然“口头管理”

Test the necessary skill points of siege lion! This article takes you to interpret the testing technology under Devops

如何才能快速正确的部署甘特图

What are the highlights of Huawei mate 40 series with HMS?

QT audio and video development 46 video transmission UDP version

Stm32f030c6t6 compatible to replace mm32spin05pf
![[graffiti Internet of things footprints] panoramic introduction of graffiti cloud platform](/img/3b/00bc81122d330c9d59909994e61027.jpg)
[graffiti Internet of things footprints] panoramic introduction of graffiti cloud platform

Common mathematical basic formulas of recursive and backtracking algorithms

Reserved battery interface, built-in charge and discharge circuit and electricity meter, quickly help easily handle hand-held applications

消防器材RFID固定资产管理系统
随机推荐
python3操作gitlab
Empty test suite appears in JUnit test
Detect certificate expiration script
Win7 AppCrash (solution)
Big data processing black Technology: revealing the parallel computing technology of Pb level data warehouse gaussdb (DWS)
7. Swarm builds clusters
Jenkins入门(二)声明式流水线Jenkins Pipeline
Erd-online free online database modeling tool
Web API interface design: swaggerui document / unified response format / unified exception handling / unified authority verification
Nodejs中使用jsonwebtoken(JWT)生成token的场景使用
Stickinengine architecture 11 message queue
Epu360: all the H5 templates you want are here, e-book, big turntable, red envelope rain, questionnaire survey
关于DevOps的七大误解,99%的人都曾中过招!
实验一
Exclusive interview of guests at | 2020 PostgreSQL Asia Conference: Wang Tao
New features of vue3
小程序商城系统插件代码该如何写?怎么用代码检查添加插件是否成功?
Message queue - Analysis
高速公路二维码定位报警系统
win7 APPCRASH(解决方法)(转)