User:Uo4tie/bot/control.py

From OpenStreetMap Wiki
Jump to navigation Jump to search

Python code to copy the informations in the sidebar of the Key:* and Tag:* description pages to the data item via MediaWiki Action API. See the Not copied ... categories in Category:Data item issues.

Copyright (C) 2026 uo4tie

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 (at your option) any later version.

This program 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 Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see <https://www.gnu.org/licenses/>.



#!/usr/bin/python3
""" 
    # SPDX-License-Identifier:  AGPL-3.0-or-later
"""
import wikibase

# wikibase.copy_to_wikibase(API,Category,language,template-parameter,for statment: p-number)

# wikibase.copy_to_wikibase("wbsetdescription","Category:Not_copied_description","DE","description",None) # description
# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not_copied_image","DE","image","P28") # image
# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not copied group","DE","group","P25") # group

# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not copied onNode","DE","onNode","P33") # onNode
# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not copied onWay","DE","onWay","P34") # onWay
# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not copied onArea","DE","onArea","P35") # onArea
# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not copied onRelation","DE","onRelation","P36") # onRelation

# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not copied osmcarto-rendering","DE","osmcarto-rendering","P39") # osmcarto-rendering

# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not copied status","DE","status","P6") # status
# wikibase.copy_to_wikibase("wbcreateclaim","Category:Not copied statuslink","DE","statuslink","P25") # statuslink