Help:Extension:FileImporter/ru
Расширения Расширение:FileImporter и FileExporter предназначены для упрощения переноса файлов из локального википроекта на Викисклад. Новая функциональность позволяет переносить файлы со всеми исходными данными, при этом факт переноса будет упомянут в истории версий.
The FileExporter provides a link to Wikimedia Commons on the local wiki and hands over a URL to the extension FileImporter. The Расширение:FileImporter is a Wikimedia Commons extension which imports the file including all data when all prerequisites are met. Technically, the files won't be "moved", but "copied".
FileImporter has been deployed to Wikimedia Commons in June 2018. To make use of it, you need to activate the FileExporter as a beta feature in your local wiki. (Exception: A few Wikimedia wikis already have the FileExporter as a default feature.)
Background
FileImporter and FileExporter aim to fulfill a request from the German-speaking community's Technical Wishlist and are developed by WMDE's tech team (WikiMedia Deutschland). More information can be found on the main project page on Meta.
Использование
Getting started
The preceding link will take you to the preferences page for the MediaWiki wiki.)
Exception: A few Wikimedia wikis already have the FileExporter as a default feature. On these wikis, you don't need to activate anything.
You don't have to activate the FileImporter on Wikimedia Commons.
2) There needs to be a configuration file for your wiki. Many files already exist, based on the files from the CommonsHelper2 tool. We're asking users to have a look at them and update or create them if needed to make sure the imports are done right.
For more info, read the documentation how the configuration files work and what they are needed for.Шаг за шагом
You need to be logged in in order to use the feature.
-
1: На локальной странице файла нажмите на вкладку «экспорт на Викисклад» (над изображением).
-
2: FileImporter проверяет, может ли файл быть импортирован, и требуется ли замена шаблонов в процессе этого. This step is based on the wiki's configuration file. Read more.
-
3: Страница предпросмотра на Викискладе показывает, что будет импортировано. Вы можете изменить название файла и отредактировать информацию на странице, затем нажмите «Import File», чтобы скопировать файл на Викисклад.
-
5: Файл импортирован, включены имя участника, загрузившего файл изначально, имя импортировавшего на Викисклад, предыдущая история файла, его исходная страница и изменения, внесённые в ходе импорта.
Как найти импортированные файлы
- В истории правок файла импорт отображается в виде нулевой правки (т. е. визуально не вносящей изменения).
If changes were made during import, an additional text revision is created.
- New revisions that are created during import are tagged with
Modified with FileImporter
.
This way it can be filtered on the recent changes page.
- Both an upload log entry and an import log entry are created and associated with the null revision and with the importing user, and timestamped with the import date.
Having both log entries is the default for uploads, although it might lead to "doubled" entries in recent changes and watchlists, see this example file and its log entries.
- For (old) imported file revisions, upload log entries are created with the date and user of the original upload to make all file revisions appear in Commons' upload log.
These revisions are also tagged with Imported with FileImporter
.
- Imported files are marked with an invisible comment that says "This file was moved here using FileImporter from" and mentions the full URL of the source file.
CirrusSearch's insource:
feature can be used to find files with this comment, e.g.: insource:"This file was moved here using FileImporter from //en.wikipedia"
. Note this also finds later derivatives of imported files, but not files where the comment was removed.
How to add categories
The message fileimporter-post-import-revision-annotation
(empty by default) can be used to add any additional wikitext to every imported file.
The message accepts two parameters:
$1
- Full URL of the source file.$2
- Time of the import in ISO 8601, e.g.2004-02-12T15:19:21+00:00
.
For example, to categorize by source wiki, an interface administrator can set the message to {{#invoke:Imported with FileImporter|main|url=$1|time=$2}}
, where the invoked Lua module ("Module:Imported with FileImporter" in this example) looks like this:
local exports = {}
function exports.main( frame )
return "[[Category:Files moved to Commons from " .. mw.uri.new( frame.args.url ).host:gsub( ".org", "" ) .. "]]"
end
return exports
План внедрения
- 2018-06-12: Export to test.wikipedia.org
- FileExporter as a beta feature on mediawiki.org and test2.wikipedia.org. OK (To test the export, you also need to be an auto-confirmed user on these wikis.)
- FileImporter on test.wikipedia.org OK
- 2018-06-25: Export to Wikimedia Commons
- 2018-07-11:
- FileExporter as a beta feature on wikisource OK
- 2019-01-16:
- 2019-09-24:
- 2020-08-05:
- Deployment as a default feature on all remaining Wikis
Links
- Main project page on Meta
- Расширение:FileImporter - extension manual
- Extension:FileImporter/List of configured wikis - FileImporter configurations
- FileExporter - extension manual
- phab:tag/move-files-to-commons/ - Phabricator project
- overview: How templates are matched with the FileImporter extension