当前位置:网站首页>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]所创,转载请带上原文链接,感谢
边栏推荐
- 10000! Ideal car recalls all defective cars: 97 accidents have occurred and losses will be expanded
- FreeSWITCH视频会议“标准”解决方案
- Mobile pixel adaptation scheme
- August 18, 2020: introduce Mr process?
- Google browser realizes video playback acceleration function
- Experiment one
- Windows 10 蓝牙管理页面'添加蓝牙或其他设备'选项点击无响应的解决方案
- 2020年新规,微信封号怎么快速解除?
- Composition of MRAM cache
- JS array the usage of array is all here (array method reconstruction, array traversal, array de duplication, array judgment and conversion)
猜你喜欢

插件Bilibili新版0.5.5

磁存储芯片STT-MRAM的特点

Stickinengine architecture 11 message queue

idea 激活到 2089 失效

【涂鸦物联网足迹】物联网基础介绍篇
![What grammar is it? ]](/img/3b/00bc81122d330c9d59909994e61027.jpg)
What grammar is it? ]

2020年新规,微信封号怎么快速解除?

Application layer software development Godfather teaches you how to refactor, senior programmers must professional skills

WebAPI接口设计:SwaggerUI文档 / 统一响应格式 / 统一异常处理 / 统一权限验证

Ora-02292: complete constraint violation (midbjdev2.sys_ C0020757) - subrecord found
随机推荐
Design of NAND flash interface control
10000! Ideal car recalls all defective cars: 97 accidents have occurred and losses will be expanded
idea 激活到 2089 失效
心理咨询app开发所具备的优点与功能
Three steps to understand Kerberos Protocol easily
2020-08-17: how to solve data skew in detail?
FreeSWITCH视频会议“标准”解决方案
python3操作Jenkins模块api
C calls SendMessage to refresh the taskbar icon (the icon does not disappear at the end of forcing)
Cloudquery v1.2.0 release
VARCHART XGantt如何在日历上表示工作日
Dynamsoft barcode reader v7.5!
How to create an interactive kernel density chart
Two dimensional code location and alarm system of Expressway
图像处理工具包ImagXpress使用教程,如何查看事件
Windows 10 Bluetooth management page 'add Bluetooth or other devices' option click no response solution
2020-08-19: what mechanism does TCP ensure reliability?
实验一
2020年新规,微信封号怎么快速解除?
Jenkins入门(二)声明式流水线Jenkins Pipeline