~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to meta.py

Added distutils setup script and plugin meta data.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
# Copyright (C) 2010  Martin von Gagern
 
2
#
 
3
# This file is part of bzr-bash-completion
 
4
#
 
5
# bzr-bash-completion free software: you can redistribute it and/or
 
6
# modify it under the terms of the GNU General Public License as
 
7
# published by the Free Software Foundation, either version 2 of the
 
8
# License, or (at your option) any later version.
 
9
#
 
10
# bzr-bash-completion is distributed in the hope that it will be
 
11
# useful, but WITHOUT ANY WARRANTY; without even the implied warranty
 
12
# of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
13
# General Public License for more details.
 
14
#
 
15
# You should have received a copy of the GNU General Public License
 
16
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
17
 
 
18
# http://doc.bazaar.canonical.com/developers/plugin-api.html#metadata-protocol
 
19
# describes these variables, which have to be imported into setup.py.
 
20
# Have a look at bzrlib._format_version_tuple for info about version 5-tuples.
 
21
bzr_plugin_name = 'bash_completion'
 
22
bzr_commands = [ 'bash-completion' ]
 
23
bzr_plugin_version = (1, 0, 0, 'dev', 0)
 
24
 
 
25
# http://doc.bazaar.canonical.com/developers/plugin-api.html#plugin-version
 
26
# describes another version tuple:
 
27
version_info = bzr_plugin_version
 
28
 
 
29
# And we also want a string representation, matching the output generated by
 
30
# bzrlib._format_version_tuple, but avoiding its sanity checks.
 
31
__version__ = '.'.join([str(x) for x in version_info[:3]])
 
32
if version_info[3] == 'final':
 
33
    __version__ = "%d.%d.%d" % version_info[:3]
 
34
elif version_info[4] == 0:
 
35
    __version__ = "%d.%d.%d%s" % version_info[:4]
 
36
else:
 
37
    __version__ = "%d.%d.%d%s%d" % version_info