mirror of
				https://github.com/osmarks/mycorrhiza.git
				synced 2025-10-31 07:33:00 +00:00 
			
		
		
		
	Rename: Leave transclusion on redirection hyphae
This commit is contained in:
		| @@ -93,9 +93,13 @@ func Rename(oldHypha hyphae.ExistingHypha, newName string, recursive bool, leave | |||||||
| 	return nil | 	return nil | ||||||
| } | } | ||||||
|  |  | ||||||
|  | const redirectionTemplate = `=> %[1]s | ✏️ %[2]s | ||||||
|  | <= %[1]s | full | ||||||
|  | ` | ||||||
|  |  | ||||||
| func leaveRedirection(oldName, newName string, hop *history.Op) error { | func leaveRedirection(oldName, newName string, hop *history.Op) error { | ||||||
| 	var ( | 	var ( | ||||||
| 		text       = fmt.Sprintf("=> %s | ✏️ %s\n", newName, util.BeautifulName(newName)) | 		text       = fmt.Sprintf(redirectionTemplate, newName, util.BeautifulName(newName)) | ||||||
| 		emptyHypha = hyphae.ByName(oldName) | 		emptyHypha = hyphae.ByName(oldName) | ||||||
| 	) | 	) | ||||||
| 	switch emptyHypha := emptyHypha.(type) { | 	switch emptyHypha := emptyHypha.(type) { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Timur Ismagilov
					Timur Ismagilov