Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
XDG Integration
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Silent mode is enabled
All outbound communications are blocked.
Learn more
.
Show more breadcrumbs
JennaHuntsman
XDG Integration
Commits
cb5289e0
Commit
cb5289e0
authored
11 years ago
by
Oz Linden
Browse files
Options
Downloads
Patches
Plain Diff
remove files incorrectly brought back from the past by merges
parent
0a61606b
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
indra/lib/python/indra/util/llversion.py
+0
-107
0 additions, 107 deletions
indra/lib/python/indra/util/llversion.py
indra/llcommon/llversionviewer.h
+0
-41
0 additions, 41 deletions
indra/llcommon/llversionviewer.h
with
0 additions
and
148 deletions
indra/lib/python/indra/util/llversion.py
deleted
100755 → 0
+
0
−
107
View file @
0a61606b
#!/usr/bin/env python
"""
\
@file llversion.py
@brief Parses llcommon/llversionserver.h and llcommon/llversionviewer.h
for the version string and channel string.
Parses hg info for branch and revision.
$LicenseInfo:firstyear=2006&license=mit$
Copyright (c) 2006-2009, Linden Research, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the
"
Software
"
), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED
"
AS IS
"
, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
$/LicenseInfo$
"""
import
re
,
sys
,
os
,
subprocess
# Methods for gathering version information from
# llversionviewer.h and llversionserver.h
def
get_src_root
():
indra_lib_python_indra_path
=
os
.
path
.
dirname
(
__file__
)
return
os
.
path
.
abspath
(
os
.
path
.
realpath
(
indra_lib_python_indra_path
+
"
/../../../../../
"
))
def
get_version_file_contents
(
version_type
):
filepath
=
get_src_root
()
+
'
/indra/llcommon/llversion%s.h
'
%
version_type
file
=
open
(
filepath
,
"
r
"
)
file_str
=
file
.
read
()
file
.
close
()
return
file_str
def
get_version
(
version_type
):
file_str
=
get_version_file_contents
(
version_type
)
m
=
re
.
search
(
'
const S32 LL_VERSION_MAJOR = (\d+);
'
,
file_str
)
VER_MAJOR
=
m
.
group
(
1
)
m
=
re
.
search
(
'
const S32 LL_VERSION_MINOR = (\d+);
'
,
file_str
)
VER_MINOR
=
m
.
group
(
1
)
m
=
re
.
search
(
'
const S32 LL_VERSION_PATCH = (\d+);
'
,
file_str
)
VER_PATCH
=
m
.
group
(
1
)
m
=
re
.
search
(
'
const S32 LL_VERSION_BUILD = (\d+);
'
,
file_str
)
VER_BUILD
=
m
.
group
(
1
)
version
=
"
%(VER_MAJOR)s.%(VER_MINOR)s.%(VER_PATCH)s.%(VER_BUILD)s
"
%
locals
()
return
version
def
get_channel
(
version_type
):
file_str
=
get_version_file_contents
(
version_type
)
m
=
re
.
search
(
'
const char \* const LL_CHANNEL =
"
(.+)
"
;
'
,
file_str
)
return
m
.
group
(
1
)
def
get_viewer_version
():
return
get_version
(
'
viewer
'
)
def
get_server_version
():
return
get_version
(
'
server
'
)
def
get_viewer_channel
():
return
get_channel
(
'
viewer
'
)
def
get_server_channel
():
return
get_channel
(
'
server
'
)
# Methods for gathering hg information
def
get_hg_repo
():
child
=
subprocess
.
Popen
([
"
hg
"
,
"
showconfig
"
,
"
paths.default
"
],
stdout
=
subprocess
.
PIPE
)
output
,
error
=
child
.
communicate
()
status
=
child
.
returncode
if
status
:
print
>>
sys
.
stderr
,
error
sys
.
exit
(
1
)
if
not
output
:
print
>>
sys
.
stderr
,
'
ERROR: cannot find repo we cloned from
'
sys
.
exit
(
1
)
return
output
def
get_hg_changeset
():
# The right thing to do would be to use the *global* revision id:
# "hg id -i"
# For the moment though, we use the parent revision:
child
=
subprocess
.
Popen
([
"
hg
"
,
"
parents
"
,
"
--template
"
,
"
{rev}
"
],
stdout
=
subprocess
.
PIPE
)
output
,
error
=
child
.
communicate
()
status
=
child
.
returncode
if
status
:
print
>>
sys
.
stderr
,
error
sys
.
exit
(
1
)
lines
=
output
.
splitlines
()
if
len
(
lines
)
>
1
:
print
>>
sys
.
stderr
,
'
ERROR: working directory has %d parents
'
%
len
(
lines
)
return
lines
[
0
]
def
using_hg
():
return
os
.
path
.
isdir
(
os
.
path
.
join
(
get_src_root
(),
'
.hg
'
))
This diff is collapsed.
Click to expand it.
indra/llcommon/llversionviewer.h
deleted
100755 → 0
+
0
−
41
View file @
0a61606b
/**
* @file llversionviewer.h
* @brief
*
* $LicenseInfo:firstyear=2002&license=viewerlgpl$
* Second Life Viewer Source Code
* Copyright (C) 2010, Linden Research, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation;
* version 2.1 of the License only.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
* Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
* $/LicenseInfo$
*/
#ifndef LL_LLVERSIONVIEWER_H
#define LL_LLVERSIONVIEWER_H
const
S32
LL_VERSION_MAJOR
=
3
;
const
S32
LL_VERSION_MINOR
=
5
;
const
S32
LL_VERSION_PATCH
=
2
;
const
S32
LL_VERSION_BUILD
=
264760
;
const
char
*
const
LL_CHANNEL
=
"Second Life Developer"
;
#if LL_DARWIN
const
char
*
const
LL_VERSION_BUNDLE_ID
=
"com.secondlife.indra.viewer"
;
#endif
#endif
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