Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
douban-api-proxy
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
captainwong
douban-api-proxy
Commits
371097eb
Commit
371097eb
authored
Feb 23, 2020
by
OzzieIsaacs
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update Updater
parent
27a18d60
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
2 deletions
+12
-2
epub.js
cps/static/js/reading/epub.js
+0
-1
updater.py
cps/updater.py
+12
-1
No files found.
cps/static/js/reading/epub.js
View file @
371097eb
...
...
@@ -42,5 +42,4 @@ var reader;
alert
(
error
);
});
}
// reader.book.package.metadata.direction= "rtl"; wait for reader reader before changing reading direction
})();
cps/updater.py
View file @
371097eb
...
...
@@ -193,7 +193,12 @@ class Updater(threading.Thread):
exclude
=
(
os
.
sep
+
'app.db'
,
os
.
sep
+
'calibre-web.log1'
,
os
.
sep
+
'calibre-web.log2'
,
os
.
sep
+
'gdrive.db'
,
os
.
sep
+
'vendor'
,
os
.
sep
+
'calibre-web.log'
,
os
.
sep
+
'.git'
,
os
.
sep
+
'client_secrets.json'
,
os
.
sep
+
'gdrive_credentials'
,
os
.
sep
+
'settings.yaml'
)
os
.
sep
+
'gdrive_credentials'
,
os
.
sep
+
'settings.yaml'
,
os
.
sep
+
'venv'
,
os
.
sep
+
'virtualenv'
,
os
.
sep
+
'access.log'
,
os
.
sep
+
'access.log1'
,
os
.
sep
+
'access.log2'
,
)
additional_path
=
self
.
is_venv
()
if
additional_path
:
exclude
=
exclude
+
(
additional_path
,)
for
root
,
dirs
,
files
in
os
.
walk
(
destination
,
topdown
=
True
):
for
name
in
files
:
old_list
.
append
(
os
.
path
.
join
(
root
,
name
)
.
replace
(
destination
,
''
))
...
...
@@ -229,6 +234,12 @@ class Updater(threading.Thread):
logger
.
debug
(
"Could not remove:
%
s"
,
item_path
)
shutil
.
rmtree
(
source
,
ignore_errors
=
True
)
def
is_venv
(
self
):
if
(
hasattr
(
sys
,
'real_prefix'
))
or
(
hasattr
(
sys
,
'base_prefix'
)
and
sys
.
base_prefix
!=
sys
.
prefix
):
return
os
.
sep
+
os
.
path
.
relpath
(
sys
.
prefix
,
constants
.
BASE_DIR
)
else
:
return
False
@
classmethod
def
_nightly_version_info
(
cls
):
if
is_sha1
(
constants
.
NIGHTLY_VERSION
[
0
])
and
len
(
constants
.
NIGHTLY_VERSION
[
1
])
>
0
:
...
...
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