Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
settingsd
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
1
Merge Requests
1
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
settingsd
Commits
e4a3f944
Commit
e4a3f944
authored
Sep 06, 2010
by
Devaev Maxim
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added log module
parent
0d6b1bfc
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
5 deletions
+6
-5
hello.py
functions/hello.py
+1
-2
main.py
main.py
+5
-3
No files found.
functions/hello.py
View file @
e4a3f944
import
sys
sys
.
path
.
append
(
".."
)
# path hook
import
settingsd.service
import
settingsd.validators
class
Hello
(
settingsd
.
service
.
FunctionObject
)
:
...
...
@@ -25,7 +24,7 @@ class Requisites(settingsd.service.Requisites) :
@classmethod
def
options
(
self
)
:
return
[
(
"hello"
,
"hello_string"
,
"Hello, World!"
,
s
ettingsd
.
validators
.
string
)
(
"hello"
,
"hello_string"
,
"Hello, World!"
,
s
tr
)
]
class
Service
(
settingsd
.
service
.
Service
)
:
...
...
main.py
View file @
e4a3f944
import
sys
import
os
from
settingsd
import
const
from
settingsd
import
application
from
settingsd
import
logger
if
__name__
==
"__main__"
:
app
=
application
.
Application
()
app
.
init
()
print
>>
sys
.
stderr
,
"Initialized"
logger
.
message
(
const
.
LOG_LEVEL_INFO
,
"Initialized"
)
try
:
app
.
run
()
except
KeyboardInterrupt
:
app
.
close
()
print
>>
sys
.
stderr
,
"
\n
Closed"
logger
.
message
(
const
.
LOG_LEVEL_INFO
,
"Closed"
)
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