Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
I
install.api
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Script
install.api
Commits
d9040bd6
Commit
d9040bd6
authored
Oct 28, 2020
by
jinkaiqiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加延迟
parent
16baba52
Pipeline
#28945
passed with stage
in 21 seconds
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
flask_app.py
flask_app.py
+1
-1
No files found.
flask_app.py
View file @
d9040bd6
...
@@ -36,13 +36,13 @@ def readonly_handler(func, path, execinfo):
...
@@ -36,13 +36,13 @@ def readonly_handler(func, path, execinfo):
这里需要实现文件权限修改的回调函数,通过onerror带入。
这里需要实现文件权限修改的回调函数,通过onerror带入。
'''
'''
os
.
chmod
(
path
,
stat
.
S_IWRITE
)
os
.
chmod
(
path
,
stat
.
S_IWRITE
)
time
.
sleep
(
0.5
)
func
(
path
)
func
(
path
)
if
os
.
path
.
exists
(
git_path
):
if
os
.
path
.
exists
(
git_path
):
if
platform
.
system
()
==
'Linux'
:
if
platform
.
system
()
==
'Linux'
:
os
.
system
(
f
"rm -rf {deploy_repo_path}"
)
os
.
system
(
f
"rm -rf {deploy_repo_path}"
)
time
.
sleep
(
1
)
else
:
else
:
shutil
.
rmtree
(
git_path
,
onerror
=
readonly_handler
)
shutil
.
rmtree
(
git_path
,
onerror
=
readonly_handler
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment