mirror of
				https://github.com/Jermolene/TiddlyWiki5
				synced 2025-10-31 07:32:59 +00:00 
			
		
		
		
	Add support for splitting standalone translations
This commit is contained in:
		
							
								
								
									
										11
									
								
								editions/translators/tiddlers/Extracting Translations.tid
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										11
									
								
								editions/translators/tiddlers/Extracting Translations.tid
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,11 @@ | ||||
| title: Extracting Translations | ||||
|  | ||||
| The [[Instructions for Translators]] yield a standalone TiddlyWiki HTML file that contains tiddlers corresponding to each translated string. | ||||
|  | ||||
| The following command is used to generate the tiddler source files for the repository: | ||||
|  | ||||
| ``` | ||||
| tiddlywiki editions/translators/ --verbose --load <path to HTML file> --build output-files | ||||
| ``` | ||||
|  | ||||
| The source files are generated in `editions/translators/output/language`. They should be copied to the appropriate `languages` directory, and an appropriate flag image placed in `icon.tid`. | ||||
| @@ -2,6 +2,7 @@ title: HelloThere | ||||
|  | ||||
| This edition of ~TiddlyWiki is for people who would like to create or update a translation for ~TiddlyWiki. It makes it possible for translators to work interactively, avoiding using Node.js and ~GitHub. | ||||
|  | ||||
| * [[Instructions]] | ||||
| * [[Instructions for Translators]] | ||||
| * [[Extracting Translations]] | ||||
|  | ||||
| See http://tiddlywiki.com for more details about ~TiddlyWiki. | ||||
|   | ||||
| @@ -1,4 +1,4 @@ | ||||
| title: Instructions | ||||
| title: Instructions for Translators | ||||
| 
 | ||||
| ! Overview | ||||
| 
 | ||||
| @@ -21,6 +21,28 @@ | ||||
| 	], | ||||
| 	"build": { | ||||
| 		"index": [ | ||||
| 			"--rendertiddler","$:/core/save/all","index.html","text/plain"] | ||||
| 			"--rendertiddler","$:/core/save/all","index.html","text/plain"], | ||||
| 		"output-files": [ | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/Buttons.multids","language/Buttons.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/ControlPanel.multids","language/ControlPanel.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/Dates.multids","language/Dates.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/EditTemplate.multids","language/EditTemplate.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/Fields.multids","language/Fields.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/Filters.multids","language/Filters.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/Import.multids","language/Import.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/Misc.multids","language/Misc.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/Search.multids","language/Search.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/SideBar.multids","language/SideBar.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/TiddlerInfo.multids","language/TiddlerInfo.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/NewJournal.multids","language/NewJournal.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/Notifications.multids","language/Notifications.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/GettingStarted.tid","language/GettingStarted.tid","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/SiteTitle.tid","language/SiteTitle.tid","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/SiteSubtitle.tid","language/SiteSubtitle.tid","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/ModuleTypes.multids","language/Docs/ModuleTypes.multids","text/plain", | ||||
| 			"--rendertiddler","$:/plugins/tiddlywiki/translators/templates/PaletteColours.multids","language/Docs/PaletteColours.multids","text/plain", | ||||
| 			"--rendertiddlers","[prefix[$:/language/Help/]removeprefix[$:/language/Help/]]","$:/plugins/tiddlywiki/translators/templates/help-tid","language/Help","text/plain",".tid", | ||||
| 			"--rendertiddlers","[prefix[$:/language/Modals/]removeprefix[$:/language/Modals/]]","$:/plugins/tiddlywiki/translators/templates/modal-tid","language/Modals","text/plain",".tid", | ||||
| 			"--rendertiddlers","[prefix[$:/language/Docs/Types/]removeprefix[$:/language/Docs/Types/]]","$:/plugins/tiddlywiki/translators/templates/type-tid","language/Types","text/plain",".tid"] | ||||
| 	} | ||||
| } | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/Buttons.multids | ||||
|  | ||||
| {{$:/language/Buttons/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/ControlPanel.multids | ||||
|  | ||||
| {{$:/language/ControlPanel/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/Dates.multids | ||||
|  | ||||
| {{[prefix[$:/language/Date/]] [prefix[$:/language/RelativeDate/]]||$:/plugins/tiddlywiki/translators/templates/filtered-multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/EditTemplate.multids | ||||
|  | ||||
| {{$:/language/EditTemplate/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/Fields.multids | ||||
|  | ||||
| {{$:/language/Docs/Fields/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/Filters.multids | ||||
|  | ||||
| {{$:/language/Filters/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/GettingStarted.tid | ||||
|  | ||||
| {{GettingStarted||$:/plugins/tiddlywiki/translators/templates/tid}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/Import.multids | ||||
|  | ||||
| {{$:/language/Import/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,18 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/Misc.multids | ||||
|  | ||||
| {{[all[tiddlers+shadows]prefix[$:/language/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Buttons/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/ControlPanel/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Date/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Docs/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/EditTemplate/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Filters/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Help/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Import/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Modals/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Notifications/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/RelativeDate/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/Search/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/SideBar/]] | ||||
| -[all[tiddlers+shadows]prefix[$:/language/TiddlerInfo/]] | ||||
| +[sort[title]]||$:/plugins/tiddlywiki/translators/templates/filtered-multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/ModuleTypes.multids | ||||
|  | ||||
| {{$:/language/Docs/ModuleTypes/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/NewJournal.multids | ||||
|  | ||||
| {{$:/config/NewJournal/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/Notifications.multids | ||||
|  | ||||
| {{$:/language/Notifications/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/PaletteColours.multids | ||||
|  | ||||
| {{$:/language/Docs/PaletteColours/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/Search.multids | ||||
|  | ||||
| {{$:/language/Search/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/SideBar.multids | ||||
|  | ||||
| {{$:/language/SideBar/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/SiteSubtitle.tid | ||||
|  | ||||
| {{$:/SiteSubtitle||$:/plugins/tiddlywiki/translators/templates/tid}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/SiteTitle.tid | ||||
|  | ||||
| {{$:/SiteTitle||$:/plugins/tiddlywiki/translators/templates/tid}} | ||||
| @@ -0,0 +1,3 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/TiddlerInfo.multids | ||||
|  | ||||
| {{$:/language/TiddlerInfo/||$:/plugins/tiddlywiki/translators/templates/multids}} | ||||
| @@ -0,0 +1,9 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/filtered-multids | ||||
|  | ||||
| \define generateMultids(filter) | ||||
| title: $:/language/ | ||||
|  | ||||
| <$list filter="""$filter$"""><$list filter="[is[current]removeprefix[$:/language/]]"><$text text=<<currentTiddler>>/></$list>: <$text text={{!!text}}/> | ||||
| </$list> | ||||
| \end | ||||
| <$macrocall $name="generateMultids" filter=<<currentTiddler>>/> | ||||
							
								
								
									
										9
									
								
								plugins/tiddlywiki/translators/templates/help-tid.tid
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								plugins/tiddlywiki/translators/templates/help-tid.tid
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/help-tid | ||||
|  | ||||
| \define generateTid(title) | ||||
| title: $:/language/Help/$title$ | ||||
| description: <$text text={{$:/language/Help/$title$!!description}}/> | ||||
|  | ||||
| <$text text={{$:/language/Help/$title$}}/> | ||||
| \end | ||||
| <$macrocall $name="generateTid" title=<<currentTiddler>>/> | ||||
							
								
								
									
										12
									
								
								plugins/tiddlywiki/translators/templates/modal-tid.tid
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										12
									
								
								plugins/tiddlywiki/translators/templates/modal-tid.tid
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,12 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/modal-tid | ||||
|  | ||||
| \define generateTid(title) | ||||
| title: $:/language/Modals/$title$ | ||||
| type: <$text text={{$:/language/Modals/$title$!!type}}/> | ||||
| subtitle: <$text text={{$:/language/Modals/$title$!!subtitle}}/> | ||||
| footer: <$text text={{$:/language/Modals/$title$!!footer}}/> | ||||
| help: <$text text={{$:/language/Modals/$title$!!help}}/> | ||||
|  | ||||
| <$text text={{$:/language/Modals/$title$}}/> | ||||
| \end | ||||
| <$macrocall $name="generateTid" title=<<currentTiddler>>/> | ||||
							
								
								
									
										9
									
								
								plugins/tiddlywiki/translators/templates/multids.tid
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										9
									
								
								plugins/tiddlywiki/translators/templates/multids.tid
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,9 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/multids | ||||
|  | ||||
| \define generateMultids(prefix) | ||||
| title: $prefix$ | ||||
|  | ||||
| <$list filter="[prefix[$prefix$]sort[title]]"><$list filter="[is[current]removeprefix[$prefix$]]"><$text text=<<currentTiddler>>/></$list>: <$text text={{!!text}}/> | ||||
| </$list> | ||||
| \end | ||||
| <$macrocall $name="generateMultids" prefix=<<currentTiddler>>/> | ||||
							
								
								
									
										8
									
								
								plugins/tiddlywiki/translators/templates/tid.tid
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								plugins/tiddlywiki/translators/templates/tid.tid
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,8 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/tid | ||||
|  | ||||
| \define generateTid(title) | ||||
| title: $title$ | ||||
|  | ||||
| <$transclude tiddler="""$title$"""/> | ||||
| \end | ||||
| <$macrocall $name="generateTid" title=<<currentTiddler>>/> | ||||
							
								
								
									
										10
									
								
								plugins/tiddlywiki/translators/templates/type-tid.tid
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								plugins/tiddlywiki/translators/templates/type-tid.tid
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | ||||
| title: $:/plugins/tiddlywiki/translators/templates/type-tid | ||||
|  | ||||
| \define generateTid(title) | ||||
| title: $:/language/Docs/Types/$title$ | ||||
| description: <$text text={{$:/language/Docs/Types/$title$!!description}}/> | ||||
| name: <$text text={{$:/language/Docs/Types/$title$!!name}}/> | ||||
| group: <$text text={{$:/language/Docs/Types/$title$!!group}}/> | ||||
|  | ||||
| \end | ||||
| <$macrocall $name="generateTid" title=<<currentTiddler>>/> | ||||
		Reference in New Issue
	
	Block a user
	 Jermolene
					Jermolene