mirror of
https://bitbucket.org/smil3y/katie.git
synced 2025-02-23 10:22:55 +00:00
update qlalr files copyright [ci skip]
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
parent
5b459cf0ec
commit
f865064e56
6 changed files with 15 additions and 29 deletions
|
@ -7,10 +7,10 @@ licenses = ['BSD', 'FDL', 'LGPL', 'LGPL3', 'LGPL21']
|
|||
lfiles = []
|
||||
for root, subdirs, files in os.walk(os.curdir):
|
||||
for sfile in files:
|
||||
if sfile.endswith(('.cpp', '.h', '.js', '.qs', '.qml', '.ui')):
|
||||
if sfile.endswith(('.cpp', '.h', '.js', '.qs', '.qml', '.ui', '.g')):
|
||||
lfiles.append('%s/%s' % (root, sfile))
|
||||
|
||||
def readlicense(sfile):
|
||||
def readlicense(sfile, replacestars):
|
||||
sheader = ''
|
||||
with open(sfile, 'r') as f:
|
||||
shouldappend = False
|
||||
|
@ -22,6 +22,8 @@ def readlicense(sfile):
|
|||
shouldappend = False
|
||||
if shouldappend:
|
||||
sheader = '%s%s' % (sheader, sline)
|
||||
if replacestars:
|
||||
sheader = sheader.replace('**', '--')
|
||||
return sheader
|
||||
|
||||
for sfile in lfiles:
|
||||
|
@ -29,10 +31,10 @@ for sfile in lfiles:
|
|||
scontent = f.read()
|
||||
for license in licenses:
|
||||
if ('$QT_BEGIN_LICENSE:%s$' % license) in scontent:
|
||||
snewheader = readlicense('%s/header.%s' % (os.curdir, license))
|
||||
soldheader = readlicense(sfile)
|
||||
snewheader = readlicense('%s/header.%s' % (os.curdir, license), sfile.endswith('.g'))
|
||||
soldheader = readlicense(sfile, False)
|
||||
snewcontent = scontent.replace(soldheader, snewheader)
|
||||
snewcontent = snewcontent.replace("2016-2019", "2016-2020")
|
||||
snewcontent = snewcontent.replace('2016-2019', '2016-2020')
|
||||
if not snewcontent == scontent:
|
||||
with open(sfile, 'w') as f:
|
||||
f.write(snewcontent)
|
||||
|
|
|
@ -83,7 +83,7 @@
|
|||
/./****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2015 The Qt Company Ltd.
|
||||
** Copyright (C) 2016-2019 Ivailo Monev
|
||||
** Copyright (C) 2016-2020 Ivailo Monev
|
||||
**
|
||||
** This file is part of the QtDeclarative module of the Katie Toolkit.
|
||||
**
|
||||
|
@ -136,7 +136,7 @@
|
|||
/:/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2015 The Qt Company Ltd.
|
||||
** Copyright (C) 2016-2019 Ivailo Monev
|
||||
** Copyright (C) 2016-2020 Ivailo Monev
|
||||
**
|
||||
** This file is part of the QtDeclarative module of the Katie Toolkit.
|
||||
**
|
||||
|
|
|
@ -62,7 +62,7 @@
|
|||
/./****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2015 The Qt Company Ltd.
|
||||
** Copyright (C) 2016-2019 Ivailo Monev
|
||||
** Copyright (C) 2016-2020 Ivailo Monev
|
||||
**
|
||||
** This file is part of the QtScript module of the Katie Toolkit.
|
||||
**
|
||||
|
@ -119,7 +119,7 @@
|
|||
/:/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2015 The Qt Company Ltd.
|
||||
** Copyright (C) 2016-2019 Ivailo Monev
|
||||
** Copyright (C) 2016-2020 Ivailo Monev
|
||||
**
|
||||
** This file is part of the QtScript module of the Katie Toolkit.
|
||||
**
|
||||
|
|
|
@ -5,16 +5,9 @@
|
|||
-- This file is part of the Qt Linguist of the Katie Toolkit.
|
||||
--
|
||||
-- $QT_BEGIN_LICENSE:LGPL$
|
||||
-- Commercial License Usage
|
||||
-- Licensees holding valid commercial Qt licenses may use this file in
|
||||
-- accordance with the commercial license agreement provided with the
|
||||
-- Software or, alternatively, in accordance with the terms contained in
|
||||
-- a written agreement between you and The Qt Company. For licensing terms
|
||||
-- and conditions see http://www.qt.io/terms-conditions. For further
|
||||
-- information use the contact form at http://www.qt.io/contact-us.
|
||||
--
|
||||
-- GNU Lesser General Public License Usage
|
||||
-- Alternatively, this file may be used under the terms of the GNU Lesser
|
||||
-- This file may be used under the terms of the GNU Lesser
|
||||
-- General Public License version 2.1 as published by the Free Software
|
||||
-- Foundation and appearing in the file LICENSE.LGPL included in the
|
||||
-- packaging of this file. Please review the following information to
|
||||
|
@ -33,7 +26,6 @@
|
|||
-- ensure the GNU General Public License version 3.0 requirements will be
|
||||
-- met: http://www.gnu.org/copyleft/gpl.html.
|
||||
--
|
||||
--
|
||||
-- $QT_END_LICENSE$
|
||||
--
|
||||
----------------------------------------------------------------------------
|
||||
|
|
|
@ -5,16 +5,9 @@
|
|||
-- This file is part of the QtCore module of the Katie Toolkit.
|
||||
--
|
||||
-- $QT_BEGIN_LICENSE:LGPL$
|
||||
-- Commercial License Usage
|
||||
-- Licensees holding valid commercial Qt licenses may use this file in
|
||||
-- accordance with the commercial license agreement provided with the
|
||||
-- Software or, alternatively, in accordance with the terms contained in
|
||||
-- a written agreement between you and The Qt Company. For licensing terms
|
||||
-- and conditions see http://www.qt.io/terms-conditions. For further
|
||||
-- information use the contact form at http://www.qt.io/contact-us.
|
||||
--
|
||||
-- GNU Lesser General Public License Usage
|
||||
-- Alternatively, this file may be used under the terms of the GNU Lesser
|
||||
-- This file may be used under the terms of the GNU Lesser
|
||||
-- General Public License version 2.1 as published by the Free Software
|
||||
-- Foundation and appearing in the file LICENSE.LGPL included in the
|
||||
-- packaging of this file. Please review the following information to
|
||||
|
@ -33,7 +26,6 @@
|
|||
-- ensure the GNU General Public License version 3.0 requirements will be
|
||||
-- met: http://www.gnu.org/copyleft/gpl.html.
|
||||
--
|
||||
--
|
||||
-- $QT_END_LICENSE$
|
||||
--
|
||||
----------------------------------------------------------------------------
|
||||
|
|
|
@ -77,7 +77,7 @@
|
|||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2015 The Qt Company Ltd.
|
||||
** Copyright (C) 2016-2019 Ivailo Monev
|
||||
** Copyright (C) 2016-2020 Ivailo Monev
|
||||
**
|
||||
** This file is part of the QLALR project on Qt Labs.
|
||||
**
|
||||
|
@ -195,7 +195,7 @@ QT_END_NAMESPACE
|
|||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2015 The Qt Company Ltd.
|
||||
** Copyright (C) 2016-2019 Ivailo Monev
|
||||
** Copyright (C) 2016-2020 Ivailo Monev
|
||||
**
|
||||
** This file is part of the QLALR project on Qt Labs.
|
||||
**
|
||||
|
|
Loading…
Add table
Reference in a new issue