Commit d6da9843 authored by Florent Fourcot's avatar Florent Fourcot

Set copyright in applications

parent 4fe15a32
......@@ -284,7 +284,7 @@ class AccountListFormatter(IFormatter):
class Boobank(ReplApplication):
APPNAME = 'boobank'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Romain Bignon, Christophe Benz'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon, Christophe Benz'
CAPS = CapBank
DESCRIPTION = "Console application allowing to list your bank accounts and get their balance, " \
"display accounts history and coming bank operations, and transfer money from an account to " \
......
......@@ -279,7 +279,7 @@ h2. Attendees
class Boobathon(ReplApplication):
APPNAME = 'boobathon'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2011-YEAR Romain Bignon'
DESCRIPTION = 'Console application to participate to a Boobathon.'
SHORT_DESCRIPTION = "participate in a Boobathon"
CAPS = CapContent
......
......@@ -141,7 +141,7 @@ class UpcomingFormatter(IFormatter):
class Boobcoming(ReplApplication):
APPNAME = 'boobcoming'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2012 Bezleputh'
COPYRIGHT = 'Copyright(C) 2012-YEAR Bezleputh'
DESCRIPTION = "Console application to see upcoming events."
SHORT_DESCRIPTION = "see upcoming events"
CAPS = CapCalendarEvent
......
......@@ -42,7 +42,7 @@ class SubscriptionsFormatter(PrettyFormatter):
class Boobill(ReplApplication):
APPNAME = 'boobill'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2012 Florent Fourcot'
COPYRIGHT = 'Copyright(C) 2012-YEAR Florent Fourcot'
DESCRIPTION = 'Console application allowing to get and download bills.'
SHORT_DESCRIPTION = "get and download bills"
CAPS = CapBill
......
......@@ -57,7 +57,7 @@ class LyricsListFormatter(PrettyFormatter):
class Booblyrics(ReplApplication):
APPNAME = 'booblyrics'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2013 Julien Veyssier'
COPYRIGHT = 'Copyright(C) 2013-YEAR Julien Veyssier'
DESCRIPTION = "Console application allowing to search for song lyrics on various websites."
SHORT_DESCRIPTION = "search and display song lyrics"
CAPS = CapLyrics
......
......@@ -236,7 +236,7 @@ class ProfileFormatter(IFormatter):
class Boobmsg(ReplApplication):
APPNAME = 'boobmsg'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Christophe Benz'
COPYRIGHT = 'Copyright(C) 2010-YEAR Christophe Benz'
DESCRIPTION = "Console application allowing to send messages on various websites and " \
"to display message threads and contents."
SHORT_DESCRIPTION = "send and receive message threads"
......
......@@ -41,7 +41,7 @@ class RentedListFormatter(PrettyFormatter):
class Boobooks(ReplApplication):
APPNAME = 'boobooks'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2012 Jeremy Monnet'
COPYRIGHT = 'Copyright(C) 2012-YEAR Jeremy Monnet'
CAPS = CapBook
DESCRIPTION = "Console application allowing to list your books rented or booked at the library, " \
"book and search new ones, get your booking history (if available)."
......
......@@ -95,7 +95,7 @@ class GaugeFormatter(IFormatter):
class Boobsize(ReplApplication):
APPNAME = 'Boobsize'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2013 Florent Fourcot'
COPYRIGHT = 'Copyright(C) 2013-YEAR Florent Fourcot'
DESCRIPTION = "Console application allowing to display various sensors and gauges values."
SHORT_DESCRIPTION = "display sensors and gauges values"
CAPS = (CapGauge)
......
......@@ -106,7 +106,7 @@ class IssuesListFormatter(PrettyFormatter):
class BoobTracker(ReplApplication):
APPNAME = 'boobtracker'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2011-YEAR Romain Bignon'
DESCRIPTION = "Console application allowing to create, edit, view bug tracking issues."
SHORT_DESCRIPTION = "manage bug tracking issues"
CAPS = CapBugTracker
......
......@@ -177,7 +177,7 @@ class PersonBiographyFormatter(PrettyFormatter):
class Cineoob(ReplApplication):
APPNAME = 'cineoob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2013 Julien Veyssier'
COPYRIGHT = 'Copyright(C) 2013-YEAR Julien Veyssier'
DESCRIPTION = "Console application allowing to search for movies and persons on various cinema databases " \
", list persons related to a movie, list movies related to a person and list common movies " \
"of two persons."
......
......@@ -75,7 +75,7 @@ class PricesFormatter(PrettyFormatter):
class Comparoob(ReplApplication):
APPNAME = 'comparoob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2012 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2012-YEAR Romain Bignon'
DESCRIPTION = "Console application to compare products."
SHORT_DESCRIPTION = "compare products"
DEFAULT_FORMATTER = 'table'
......
......@@ -75,7 +75,7 @@ class RecipeListFormatter(PrettyFormatter):
class Cookboob(ReplApplication):
APPNAME = 'cookboob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2013 Julien Veyssier'
COPYRIGHT = 'Copyright(C) 2013-YEAR Julien Veyssier'
DESCRIPTION = "Console application allowing to search for recipes on various websites."
SHORT_DESCRIPTION = "search and consult recipes"
CAPS = CapRecipe
......
......@@ -81,7 +81,7 @@ class HousingListFormatter(PrettyFormatter):
class Flatboob(ReplApplication):
APPNAME = 'flatboob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2012 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2012-YEAR Romain Bignon'
DESCRIPTION = "Console application to search for housing."
SHORT_DESCRIPTION = "search for housing"
CAPS = CapHousing
......
......@@ -48,7 +48,7 @@ class GalleryListFormatter(PrettyFormatter):
class Galleroob(ReplApplication):
APPNAME = 'galleroob'
VERSION = '1.1'
COPYRIGHT = u'Copyright(C) 2011 Noé Rubinstein'
COPYRIGHT = u'Copyright(C) 2011-2014 Noé Rubinstein'
DESCRIPTION = 'galleroob browses and downloads web image galleries'
SHORT_DESCRIPTION = 'browse and download web image galleries'
CAPS = CapGallery
......
......@@ -29,7 +29,7 @@ __all__ = ['Geolooc']
class Geolooc(ReplApplication):
APPNAME = 'geolooc'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
DESCRIPTION = "Console application allowing to geolocalize IP addresses."
SHORT_DESCRIPTION = "geolocalize IP addresses"
CAPS = CapGeolocIp
......
......@@ -76,7 +76,7 @@ class JobAdvertListFormatter(PrettyFormatter):
class Handjoob(ReplApplication):
APPNAME = 'handjoob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2012 Bezleputh'
COPYRIGHT = 'Copyright(C) 2012-YEAR Bezleputh'
DESCRIPTION = "Console application to search for a job."
SHORT_DESCRIPTION = "search for a job"
CAPS = CapJob
......
......@@ -49,7 +49,7 @@ class EventListFormatter(PrettyFormatter):
class HaveDate(Boobmsg):
APPNAME = 'havedate'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2012 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
DESCRIPTION = "Console application allowing to interact with various dating websites " \
"and to optimize seduction algorithmically."
SHORT_DESCRIPTION = "interact with dating websites"
......
......@@ -279,7 +279,7 @@ class Masstransit(Application):
"Application Class"
APPNAME = 'masstransit'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Julien Hébert'
COPYRIGHT = 'Copyright(C) 2010-YEAR Julien Hébert'
DESCRIPTION = "Maemo application allowing to search for train stations and get departure times."
SHORT_DESCRIPTION = "search for train stations and departures"
......
......@@ -90,7 +90,7 @@ class MonboobScheduler(Scheduler):
class Monboob(ReplApplication):
APPNAME = 'monboob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
DESCRIPTION = 'Daemon allowing to regularly check for new messages on various websites, ' \
'and send an email for each message, and post a reply to a message on a website.'
SHORT_DESCRIPTION = "daemon to send and check messages"
......
......@@ -85,7 +85,7 @@ class StatusFormatter(IFormatter):
class Parceloob(ReplApplication):
APPNAME = 'parceloob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2013 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2013-YEAR Romain Bignon'
CAPS = CapParcel
DESCRIPTION = "Console application to track your parcels."
SHORT_DESCRIPTION = "manage your parcels"
......
......@@ -34,7 +34,7 @@ __all__ = ['Pastoob']
class Pastoob(ReplApplication):
APPNAME = 'pastoob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2011-2013 Laurent Bachelier'
COPYRIGHT = 'Copyright(C) 2011-YEAR Laurent Bachelier'
DESCRIPTION = "Console application allowing to post and get pastes from pastebins."
SHORT_DESCRIPTION = "post and get pastes from pastebins"
CAPS = CapPaste
......
......@@ -27,7 +27,7 @@ from .main_window import MainWindow
class QBoobMsg(QtApplication):
APPNAME = 'qboobmsg'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
DESCRIPTION = "Qt application allowing to read messages on various websites and reply to them."
SHORT_DESCRIPTION = "send and receive message threads"
CAPS = CapMessages
......
......@@ -29,7 +29,7 @@ from .main_window import MainWindow
class QCineoob(QtApplication):
APPNAME = 'qcineoob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2013 Julien Veyssier'
COPYRIGHT = 'Copyright(C) 2013-YEAR Julien Veyssier'
DESCRIPTION = "Qt application allowing to search movies, people, torrent and subtitles."
SHORT_DESCRIPTION = "search movies, people, torrent and subtitles"
CAPS = CapCinema, CapTorrent, CapSubtitle
......
......@@ -27,7 +27,7 @@ from .main_window import MainWindow
class QCookboob(QtApplication):
APPNAME = 'qcookboob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2013 Julien Veyssier'
COPYRIGHT = 'Copyright(C) 2013-2014 Julien Veyssier'
DESCRIPTION = "Qt application allowing to search recipes."
SHORT_DESCRIPTION = "search recipes"
CAPS = CapRecipe
......
......@@ -28,7 +28,7 @@ from .main_window import MainWindow
class QFlatBoob(QtApplication):
APPNAME = 'qflatboob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2012 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-2014 Romain Bignon'
DESCRIPTION = "Qt application to search for housing."
SHORT_DESCRIPTION = "search for housing"
CAPS = CapHousing
......
......@@ -28,7 +28,7 @@ from .main_window import MainWindow
class QHandJoob(QtApplication):
APPNAME = 'qhandjoob'
VERSION = '1.1'
COPYRIGHT = u'Copyright(C) 2013 Sébastien Monel'
COPYRIGHT = u'Copyright(C) 2013-2014 Sébastien Monel'
DESCRIPTION = "Qt application to search for job."
SHORT_DESCRIPTION = "search for job"
CAPS = CapJob
......
......@@ -27,7 +27,7 @@ from .main_window import MainWindow
class QHaveDate(QtApplication):
APPNAME = 'qhavedate'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2012 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-2014 Romain Bignon'
DESCRIPTION = "Qt application allowing to interact with various dating websites."
SHORT_DESCRIPTION = "interact with dating websites"
CAPS = CapDating
......
......@@ -27,7 +27,7 @@ from .main_window import MainWindow
class QVideoob(QtApplication):
APPNAME = 'qvideoob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-2014 Romain Bignon'
DESCRIPTION = "Qt application allowing to search videos on various websites and play them."
SHORT_DESCRIPTION = "search and play videos"
CAPS = CapVideo
......
......@@ -26,7 +26,7 @@ from .main_window import MainWindow
class QWebContentEdit(QtApplication):
APPNAME = 'qwebcontentedit'
VERSION = '1.1'
COPYRIGHT = u'Copyright(C) 2011 Clément Schreiner'
COPYRIGHT = u'Copyright(C) 2011-2014 Clément Schreiner'
DESCRIPTION = "Qt application allowing to manage content of various websites."
SHORT_DESCRIPTION = "manage websites content"
CAPS = CapContent
......
......@@ -24,7 +24,7 @@ from weboob.tools.application.qt import BackendCfg, QtApplication
class QWeboobCfg(QtApplication):
APPNAME = 'qweboobcfg'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-2014 Romain Bignon'
DESCRIPTION = "weboob-config-qt is a graphical application to add/edit/remove backends, " \
"and to register new website accounts."
SHORT_DESCRIPTION = "manage backends or register new accounts"
......
......@@ -126,7 +126,7 @@ class PlaylistTrackListInfoFormatter(PrettyFormatter):
class Radioob(ReplApplication):
APPNAME = 'radioob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2013 Romain Bignon\nCopyright(C) 2013 Pierre Maziere'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon\nCopyright(C) YEAR Pierre Maziere'
DESCRIPTION = "Console application allowing to search for web radio stations, listen to them and get information " \
"like the current song."
SHORT_DESCRIPTION = "search, show or listen to radio stations"
......
......@@ -86,7 +86,7 @@ class SubtitleListFormatter(PrettyFormatter):
class Suboob(ReplApplication):
APPNAME = 'suboob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2013 Julien Veyssier'
COPYRIGHT = 'Copyright(C) 2013-YEAR Julien Veyssier'
DESCRIPTION = "Console application allowing to search for subtitles on various services " \
"and download them."
SHORT_DESCRIPTION = "search and download subtitles"
......
......@@ -48,7 +48,7 @@ class XmlTranslationFormatter(IFormatter):
class Translaboob(ReplApplication):
APPNAME = 'translaboob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2012 Lucien Loiseau'
COPYRIGHT = 'Copyright(C) 2012-YEAR Lucien Loiseau'
DESCRIPTION = "Console application to translate text from one language to another"
SHORT_DESCRIPTION = "translate text from one language to another"
CAPS = CapTranslate
......
......@@ -67,7 +67,7 @@ class StationsFormatter(PrettyFormatter):
class Traveloob(ReplApplication):
APPNAME = 'traveloob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2013 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
DESCRIPTION = "Console application allowing to search for train stations and get departure times."
SHORT_DESCRIPTION = "search for train stations and departures"
CAPS = CapTravel
......
......@@ -54,7 +54,7 @@ class VideoListFormatter(PrettyFormatter):
class Videoob(ReplApplication):
APPNAME = 'videoob'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Christophe Benz, Romain Bignon, John Obbele'
COPYRIGHT = 'Copyright(C) 2010-YEAR Christophe Benz, Romain Bignon, John Obbele'
DESCRIPTION = "Console application allowing to search for videos on various websites, " \
"play and download them and get information."
SHORT_DESCRIPTION = "search and play videos"
......
......@@ -35,7 +35,7 @@ __all__ = ['WebContentEdit']
class WebContentEdit(ReplApplication):
APPNAME = 'webcontentedit'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
DESCRIPTION = "Console application allowing to display and edit contents on various websites."
SHORT_DESCRIPTION = "manage websites content"
CAPS = CapContent
......
......@@ -34,7 +34,7 @@ __all__ = ['WeboobCfg']
class WeboobCfg(ReplApplication):
APPNAME = 'weboob-config'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2012 Christophe Benz, Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Christophe Benz, Romain Bignon'
DESCRIPTION = "Weboob-Config is a console application to add/edit/remove backends, " \
"and to register new website accounts."
SHORT_DESCRIPTION = "manage backends or register new accounts"
......
......@@ -28,7 +28,7 @@ __all__ = ['WeboobCli']
class WeboobCli(ReplApplication):
APPNAME = 'weboob-cli'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
SYNOPSIS = 'Usage: %prog [-dqv] [-b backends] [-cnfs] capability method [arguments..]\n'
SYNOPSIS += ' %prog [--help] [--version]'
DESCRIPTION = "Weboob-Cli is a console application to call a specific method on backends " \
......
......@@ -27,7 +27,7 @@ from weboob.tools.application.base import Application
class WeboobDebug(Application):
APPNAME = 'weboobdebug'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2011 Christophe Benz'
COPYRIGHT = 'Copyright(C) 2010-YEAR Christophe Benz'
DESCRIPTION = "Weboob-Debug is a console application to debug backends."
SHORT_DESCRIPTION = "debug backends"
......
......@@ -39,7 +39,7 @@ __all__ = ['WeboobRepos']
class WeboobRepos(ReplApplication):
APPNAME = 'weboob-repos'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2012 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2012-YEAR Romain Bignon'
DESCRIPTION = "Weboob-repos is a console application to manage a Weboob Repository."
SHORT_DESCRIPTION = "manage a weboob repository"
COMMANDS_FORMATTERS = {'backends': 'table',
......
......@@ -91,7 +91,7 @@ class TorrentListFormatter(PrettyFormatter):
class Weboorrents(ReplApplication):
APPNAME = 'weboorrents'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2012 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
DESCRIPTION = "Console application allowing to search for torrents on various trackers " \
"and download .torrent files."
SHORT_DESCRIPTION = "search and download torrents"
......
......@@ -60,7 +60,7 @@ class CitiesFormatter(PrettyFormatter):
class WetBoobs(ReplApplication):
APPNAME = 'wetboobs'
VERSION = '1.1'
COPYRIGHT = 'Copyright(C) 2010-2014 Romain Bignon'
COPYRIGHT = 'Copyright(C) 2010-YEAR Romain Bignon'
DESCRIPTION = "Console application allowing to display weather and forecasts in your city."
SHORT_DESCRIPTION = "display weather and forecasts"
CAPS = CapWeather
......
......@@ -23,6 +23,7 @@ from __future__ import print_function
import logging
import optparse
from optparse import OptionGroup, OptionParser
from datetime import datetime
import locale
import os
import sys
......@@ -260,7 +261,8 @@ class Application(object):
version = None
if self.VERSION:
if self.COPYRIGHT:
version = '%s v%s %s' % (self.APPNAME, self.VERSION, self.COPYRIGHT)
copyright = self.COPYRIGHT.replace('YEAR', '%d' % datetime.today().year)
version = '%s v%s %s' % (self.APPNAME, self.VERSION, copyright)
else:
version = '%s v%s' % (self.APPNAME, self.VERSION)
return version
......
......@@ -24,6 +24,7 @@ from cmd import Cmd
import logging
import re
from optparse import OptionGroup, OptionParser, IndentedHelpFormatter
from datetime import datetime
import os
from weboob.capabilities.base import FieldNotFound, BaseObject, UserError
......@@ -113,9 +114,10 @@ class ReplApplication(Cmd, ConsoleApplication):
Cmd.__init__(self)
ConsoleApplication.__init__(self, ReplOptionParser(self.SYNOPSIS, version=self._get_optparse_version()))
copyright = self.COPYRIGHT.replace('YEAR', '%d' % datetime.today().year).encode(self.encoding)
self.intro = '\n'.join(('Welcome to %s%s%s v%s' % (self.BOLD, self.APPNAME, self.NC, self.VERSION),
'',
self.COPYRIGHT.encode(self.encoding),
copyright,
'This program is free software: you can redistribute it and/or modify',
'it under the terms of the GNU Affero General Public License as published by',
'the Free Software Foundation, either version 3 of the License, or',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment