Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
synapse
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Timo Ley
synapse
Commits
b33a4cd6
Commit
b33a4cd6
authored
10 years ago
by
Erik Johnston
Browse files
Options
Downloads
Plain Diff
Merge pull request #86 from matrix-org/v0.7.1-r2
V0.7.1 r2
parents
2b45ca15
a87c56c6
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
synapse/__init__.py
+1
-1
1 addition, 1 deletion
synapse/__init__.py
synapse/app/homeserver.py
+56
-53
56 additions, 53 deletions
synapse/app/homeserver.py
with
57 additions
and
54 deletions
synapse/__init__.py
+
1
−
1
View file @
b33a4cd6
...
@@ -16,4 +16,4 @@
...
@@ -16,4 +16,4 @@
"""
This is a reference implementation of a Matrix home server.
"""
This is a reference implementation of a Matrix home server.
"""
"""
__version__
=
"
0.7.1-r
1
"
__version__
=
"
0.7.1-r
2
"
This diff is collapsed.
Click to expand it.
synapse/app/homeserver.py
+
56
−
53
View file @
b33a4cd6
...
@@ -210,61 +210,64 @@ class SynapseHomeServer(HomeServer):
...
@@ -210,61 +210,64 @@ class SynapseHomeServer(HomeServer):
def
get_version_string
():
def
get_version_string
():
null
=
open
(
os
.
devnull
,
'
w
'
)
cwd
=
os
.
path
.
dirname
(
os
.
path
.
abspath
(
__file__
))
try
:
try
:
git_branch
=
subprocess
.
check_output
(
null
=
open
(
os
.
devnull
,
'
w
'
)
[
'
git
'
,
'
rev-parse
'
,
'
--abbrev-ref
'
,
'
HEAD
'
],
cwd
=
os
.
path
.
dirname
(
os
.
path
.
abspath
(
__file__
))
stderr
=
null
,
try
:
cwd
=
cwd
,
git_branch
=
subprocess
.
check_output
(
).
strip
()
[
'
git
'
,
'
rev-parse
'
,
'
--abbrev-ref
'
,
'
HEAD
'
],
git_branch
=
"
b=
"
+
git_branch
stderr
=
null
,
except
subprocess
.
CalledProcessError
:
cwd
=
cwd
,
git_branch
=
""
).
strip
()
git_branch
=
"
b=
"
+
git_branch
try
:
except
subprocess
.
CalledProcessError
:
git_tag
=
subprocess
.
check_output
(
git_branch
=
""
[
'
git
'
,
'
describe
'
,
'
--exact-match
'
],
stderr
=
null
,
try
:
cwd
=
cwd
,
git_tag
=
subprocess
.
check_output
(
).
strip
()
[
'
git
'
,
'
describe
'
,
'
--exact-match
'
],
git_tag
=
"
t=
"
+
git_tag
stderr
=
null
,
except
subprocess
.
CalledProcessError
:
cwd
=
cwd
,
git_tag
=
""
).
strip
()
git_tag
=
"
t=
"
+
git_tag
try
:
except
subprocess
.
CalledProcessError
:
git_commit
=
subprocess
.
check_output
(
git_tag
=
""
[
'
git
'
,
'
rev-parse
'
,
'
--short
'
,
'
HEAD
'
],
stderr
=
null
,
try
:
cwd
=
cwd
,
git_commit
=
subprocess
.
check_output
(
).
strip
()
[
'
git
'
,
'
rev-parse
'
,
'
--short
'
,
'
HEAD
'
],
except
subprocess
.
CalledProcessError
:
stderr
=
null
,
git_commit
=
""
cwd
=
cwd
,
).
strip
()
try
:
except
subprocess
.
CalledProcessError
:
dirty_string
=
"
-this_is_a_dirty_checkout
"
git_commit
=
""
is_dirty
=
subprocess
.
check_output
(
[
'
git
'
,
'
describe
'
,
'
--dirty=
'
+
dirty_string
],
try
:
stderr
=
null
,
dirty_string
=
"
-this_is_a_dirty_checkout
"
cwd
=
cwd
,
is_dirty
=
subprocess
.
check_output
(
).
strip
().
endswith
(
dirty_string
)
[
'
git
'
,
'
describe
'
,
'
--dirty=
'
+
dirty_string
],
stderr
=
null
,
git_dirty
=
"
dirty
"
if
is_dirty
else
""
cwd
=
cwd
,
except
subprocess
.
CalledProcessError
:
).
strip
().
endswith
(
dirty_string
)
git_dirty
=
""
git_dirty
=
"
dirty
"
if
is_dirty
else
""
if
git_branch
or
git_tag
or
git_commit
or
git_dirty
:
except
subprocess
.
CalledProcessError
:
git_version
=
"
,
"
.
join
(
git_dirty
=
""
s
for
s
in
(
git_branch
,
git_tag
,
git_commit
,
git_dirty
,)
if
git_branch
or
git_tag
or
git_commit
or
git_dirty
:
if
s
git_version
=
"
,
"
.
join
(
)
s
for
s
in
(
git_branch
,
git_tag
,
git_commit
,
git_dirty
,)
return
(
if
s
"
Synapse/%s (%s)
"
%
(
synapse
.
__version__
,
git_version
,
)
)
).
encode
(
"
ascii
"
)
return
(
"
Synapse/%s (%s)
"
%
(
synapse
.
__version__
,
git_version
,
)
).
encode
(
"
ascii
"
)
except
Exception
as
e
:
logger
.
warn
(
"
Failed to check for git repository: %s
"
,
e
)
return
(
"
Synapse/%s
"
%
(
synapse
.
__version__
,)).
encode
(
"
ascii
"
)
return
(
"
Synapse/%s
"
%
(
synapse
.
__version__
,)).
encode
(
"
ascii
"
)
...
...
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