Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
bliss
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
494
Issues
494
List
Boards
Labels
Service Desk
Milestones
Jira
Jira
Merge Requests
135
Merge Requests
135
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Bliss
bliss
Commits
42f65686
Commit
42f65686
authored
Sep 26, 2016
by
Sebastien Petitdemange
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
settings: added scan helper function.
parent
ad2e6a56
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
bliss/config/settings.py
bliss/config/settings.py
+12
-0
No files found.
bliss/config/settings.py
View file @
42f65686
...
...
@@ -97,6 +97,18 @@ def write_decorator(func):
return
func
(
self
,
value
,
**
keys
)
return
_write
def
scan
(
match
=
'*'
,
count
=
1000
,
connection
=
None
):
if
connection
is
None
:
connection
=
get_cache
()
cursor
=
0
while
1
:
cursor
,
values
=
connection
.
scan
(
cursor
=
cursor
,
match
=
match
,
count
=
count
)
for
val
in
values
:
yield
val
if
int
(
cursor
)
==
0
:
break
class
SimpleSetting
(
object
):
def
__init__
(
self
,
name
,
connection
=
None
,
read_type_conversion
=
auto_conversion
,
...
...
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