Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
irker
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package registry
Model registry
Operate
Terraform modules
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
iDB
irker
Commits
0dd71e00
Commit
0dd71e00
authored
Oct 4, 2012
by
Eric S. Raymond
Browse files
Options
Downloads
Patches
Plain Diff
Change the filtering so standard error is not captured.
parent
7468a308
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
irkerhook.py
+4
-3
4 additions, 3 deletions
irkerhook.py
irkerhook.xml
+3
-0
3 additions, 0 deletions
irkerhook.xml
with
7 additions
and
3 deletions
irkerhook.py
+
4
−
3
View file @
0dd71e00
...
...
@@ -37,7 +37,7 @@ default_channels = "irc://chat.freenode.net/%(project)s,irc://chat.freenode.net/
# No user-serviceable parts below this line:
#
import
os
,
sys
,
commands
,
socket
,
urllib
import
os
,
sys
,
commands
,
socket
,
urllib
,
subprocess
from
pipes
import
quote
as
shellquote
try
:
import
simplejson
as
json
# Faster, also makes us Python-2.4-compatible
...
...
@@ -370,8 +370,9 @@ def ship(extractor, commit, debug):
# This is where we apply filtering
if
extractor
.
filtercmd
:
data
=
do
(
'
%s %s
'
%
(
shellquote
(
extractor
.
filtercmd
),
shellquote
(
json
.
dumps
(
metadata
.
__dict__
))))
cmd
=
'
%s %s
'
%
(
shellquote
(
extractor
.
filtercmd
),
shellquote
(
json
.
dumps
(
metadata
.
__dict__
)))
data
=
subprocess
.
Popen
(
cmd
,
shell
=
True
,
stdout
=
subprocess
.
PIPE
).
stdout
.
read
()
try
:
metadata
.
__dict__
.
update
(
json
.
loads
(
data
))
except
ValueError
:
...
...
This diff is collapsed.
Click to expand it.
irkerhook.xml
+
3
−
0
View file @
0dd71e00
...
...
@@ -324,6 +324,9 @@ print json.dumps(metadata)
# end
</programlisting>
<para>
Standard error is available to the hook for progress and
error messages.
</para>
</refsect2>
</refsect1>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment