-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Release 1.0.3: accept drag/drop of .EPUB files and process all files …
…within the EPUB. Added a LangTag DropScript which finds a lang and/or xml:lang attribute on <body> and moves them to <html>. Added more patterns to UpdateClass DropScript. #17
- Loading branch information
1 parent
ec7daed
commit 352c7a5
Showing
19 changed files
with
1,790 additions
and
49 deletions.
There are no files selected for viewing
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"acceptFileNameExtensions": [ "html", "htm", "xhtml", "xht" ], | ||
"acceptFileNameExtensions": [ "html", "htm", "xhtml" ], | ||
"backupFileNameExtension": "old", | ||
"maxBackupCount": 5 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
# LangTag.php | ||
|
||
## What it does | ||
|
||
AutoTitle.php is a command-line PHP script which can process an HTML file. | ||
|
||
It will look for the <body> and <html> tags. | ||
|
||
It will move any attributes lang=... or xml:lang=... from the <body> tag up to the <html> tag | ||
|
||
## Configuration | ||
|
||
LangTag.php will look for a file LangTag.config.txt nearby. In that file you can set | ||
or override configuration options. | ||
|
||
The names of these options are case-sensitive. | ||
|
||
### acceptFileNameExtensions | ||
|
||
Optional. The script will ignore any files whose file name does not end in one of the listed extensions | ||
|
||
The default when this is omitted is: | ||
|
||
"acceptFileNameExtensions": [ "html", "htm", "xhtml" ] | ||
|
||
### backupFileNameExtension | ||
|
||
Optional. The file name extension to use for backup files | ||
|
||
The default when this is omitted is: | ||
|
||
"backupFileNameExtension": "old" | ||
|
||
### logLevel | ||
|
||
Set to 0, 1, 2, 3, or 4. Depending on the number, more or less logging information will be | ||
provided. Useful for diagnostics when the script does not seem to work correctly. | ||
|
||
The default when this is omitted is: | ||
|
||
"logLevel": 0 | ||
|
||
### maxBackupCount | ||
|
||
Optional. How many backup files to keep. | ||
|
||
The default when this is omitted is: | ||
|
||
"maxBackupCount": 5 | ||
|
||
If maxBackupCount is 0, no backups are made | ||
|
||
If maxBackupCount is greater than zero the backups will be | ||
|
||
SomeFile.xhtml -> | ||
SomeFile.xhtml.old | ||
SomeFile.xhtml_1.old | ||
SomeFile.xhtml_2.old | ||
... | ||
SomeFile.xhtml_5.old | ||
|
||
The SomeFile.xhtml.old is special: once made, it is never overwritten. It | ||
stores the content of the original file from before you ran the script for the | ||
first time. | ||
|
||
SomeFile.xhtml_1.old, SomeFile.xhtml_2.old... rotate. The _1 file is the latest, | ||
the _5 file is the oldest. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
{ | ||
} |
Oops, something went wrong.