Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eepm
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
eepm
Commits
ee7c3fa0
Commit
ee7c3fa0
authored
9 years ago
by
Vitaly Lipatov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
check_updated_repo: run update if repo info older than 1 day
parent
13176b37
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
epm-check_updated_repo
bin/epm-check_updated_repo
+4
-2
No files found.
bin/epm-check_updated_repo
View file @
ee7c3fa0
#!/bin/sh
#!/bin/sh
#
#
# Copyright (C) 2014 Etersoft
# Copyright (C) 2014
, 2015
Etersoft
# Copyright (C) 2014 Vitaly Lipatov <lav@etersoft.ru>
# Copyright (C) 2014
, 2015
Vitaly Lipatov <lav@etersoft.ru>
#
#
# This program is free software: you can redistribute it and/or modify
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# it under the terms of the GNU Affero General Public License as published by
...
@@ -24,6 +24,8 @@ __is_repo_info_download()
...
@@ -24,6 +24,8 @@ __is_repo_info_download()
if
[
-r
/var/cache/apt
]
;
then
if
[
-r
/var/cache/apt
]
;
then
# FIXME: only if root permissions
# FIXME: only if root permissions
test
-r
/var/cache/apt/pkgcache.bin
||
return
test
-r
/var/cache/apt/pkgcache.bin
||
return
# if repo older than 1 day, return false
test
-n
"
$(
find /var/cache/apt/pkgcache.bin
-ctime
+1
)
"
||
return
fi
fi
;;
;;
*
)
*
)
...
...
This diff is collapsed.
Click to expand it.
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