texlive[74305] Master/texmf-dist: gregoriotex (26feb25)
commits+karl at tug.org
commits+karl at tug.org
Wed Feb 26 22:12:09 CET 2025
Revision: 74305
https://tug.org/svn/texlive?view=revision&revision=74305
Author: karl
Date: 2025-02-26 22:12:09 +0100 (Wed, 26 Feb 2025)
Log Message:
-----------
gregoriotex (26feb25)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/luatex/gregoriotex/CHANGELOG.md
trunk/Master/texmf-dist/doc/luatex/gregoriotex/GregorioNabcRef.pdf
trunk/Master/texmf-dist/doc/luatex/gregoriotex/GregorioRef.pdf
trunk/Master/texmf-dist/doc/luatex/gregoriotex/GregorioRef.tex
trunk/Master/texmf-dist/fonts/source/gregoriotex/squarize.py
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-hole.ttf
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-hollow.ttf
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-op-hole.ttf
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-op-hollow.ttf
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-op.ttf
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae.ttf
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/gregall.ttf
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/grelaon.ttf
trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/gresgmodern.ttf
trunk/Master/texmf-dist/scripts/gregoriotex/uninstall-gtex.sh
trunk/Master/texmf-dist/tex/lualatex/gregoriotex/gregoriosyms.sty
trunk/Master/texmf-dist/tex/lualatex/gregoriotex/gregoriotex.sty
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-chars.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-common.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-gsp-default.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-main.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-nabc.lua
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-nabc.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-signs.lua
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-signs.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-spaces.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-syllable.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-symbols.lua
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-symbols.tex
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex.lua
trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex.tex
Added Paths:
-----------
trunk/Master/texmf-dist/source/luatex/gregoriotex/gregorio-6.1.0-rc1.zip
Removed Paths:
-------------
trunk/Master/texmf-dist/source/luatex/gregoriotex/gregorio-6.1.0-beta2.zip
Modified: trunk/Master/texmf-dist/doc/luatex/gregoriotex/CHANGELOG.md
===================================================================
--- trunk/Master/texmf-dist/doc/luatex/gregoriotex/CHANGELOG.md 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/doc/luatex/gregoriotex/CHANGELOG.md 2025-02-26 21:12:09 UTC (rev 74305)
@@ -8,6 +8,11 @@
## [Unreleased][CTAN]
+## [6.1.0-rc1] - 2025-02-26
+
+
+
+
## [6.1.0-beta2] - 2025-02-17
### Fixed
- Multiple Scribus render frames were all using the same file name, which would result in the same score appearing in all render frames. This change makes the score files use an available Scribus variable to force multiple file names.
@@ -20,12 +25,14 @@
- When fancyhdr and GregorioTeX are used together, GregorioTeX's disabling of hyphenation and its `post_linebreak` modification of the `post_linebreak_filter` interfere with multiline headers. Using the `fancyhdr/before` and `fancyhdr/after` hooks we temporarily reenable hyphenation and disable our `post_linebreak` modification while headers and footers are being processed in the middle of a score. See [#1603](https://github.com/gregorio-project/gregorio/issues/1603).
- Fixed a bug that could cause a hyphen to appear on the wrong line. See [#1319](https://github.com/gregorio-project/gregorio/issues/1319).
- Fixed the placement of above-lines text (`<alt>`) relative to a note above the staff or when the number of staff lines is not 4. See [#1613](https://github.com/gregorio-project/gregorio/issues/1613) and [#1614](https://github.com/gregorio-project/gregorio/issues/1614).
-- Fixed a bug where the above-lines text (`<alt>`) could collid with a note above the staff. See [#1613](https://github.com/gregorio-project/gregorio/issues/1613).
+- Fixed a bug where the above-lines text (`<alt>`) could collide with a note above the staff. See [#1613](https://github.com/gregorio-project/gregorio/issues/1613).
- Fixed a bug that could cause the clef and staff to be printed too high. See [#1503](https://github.com/gregorio-project/gregorio/issues/1503).
### Changed
-- Modified gregorio to append to the log file specified as an argument and to send early messages to it. See [#1541](https://github.com/gregorio-project/gregorio/issues/1541).
+- Modified gregorio to write to the log file specified as an argument and to send all messages to it (except errors about opening the log file itself). See [#1541](https://github.com/gregorio-project/gregorio/issues/1541) and [#1628](https://github.com/gregorio-project/gregorio/issues/1628).
- Defined an output directory for gtex and glog files. Default is `tmp-gre`. This can be changed using `\gresetoutputdir{...}`. Fixes [#1393](https://github.com/gregorio-project/gregorio/issues/1393), [#1542](https://github.com/gregorio-project/gregorio/issues/1542), and [#1571](https://github.com/gregorio-project/gregorio/issues/1571).
+- GregorioTeX no longer searches for and reuses existing gtex files using kpathsea; it only looks in the output directory.
+- If gtex or glog files from other versions of gregorio are found either in the same directory as the gabc file or in the output directory, they are deleted.
- gabc.vim has been expanded into a proper vim plugin.
### Added
Modified: trunk/Master/texmf-dist/doc/luatex/gregoriotex/GregorioNabcRef.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/luatex/gregoriotex/GregorioRef.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/luatex/gregoriotex/GregorioRef.tex
===================================================================
--- trunk/Master/texmf-dist/doc/luatex/gregoriotex/GregorioRef.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/doc/luatex/gregoriotex/GregorioRef.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -183,7 +183,7 @@
\vspace{1cm}
- \large Version \textbf{6.1.0-beta2}, 17 February 2025 %% PARSE_VERSION_DATE
+ \large Version \textbf{6.1.0-rc1}, 26 February 2025 %% PARSE_VERSION_DATE
\vspace{1.5cm}
\gresetlinecolor{gregoriocolor}
Modified: trunk/Master/texmf-dist/fonts/source/gregoriotex/squarize.py
===================================================================
--- trunk/Master/texmf-dist/fonts/source/gregoriotex/squarize.py 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/fonts/source/gregoriotex/squarize.py 2025-02-26 21:12:09 UTC (rev 74305)
@@ -89,7 +89,7 @@
14 : 'Fourteen',
}
-GREGORIO_VERSION = '6.1.0-beta2'
+GREGORIO_VERSION = '6.1.0-rc1'
# The unicode character at which we start our numbering:
# U+E000 is the start of the BMP Private Use Area
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-hole.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-hollow.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-op-hole.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-op-hollow.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae-op.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/greciliae.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/gregall.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/grelaon.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/fonts/truetype/public/gregoriotex/gresgmodern.ttf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/scripts/gregoriotex/uninstall-gtex.sh
===================================================================
--- trunk/Master/texmf-dist/scripts/gregoriotex/uninstall-gtex.sh 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/scripts/gregoriotex/uninstall-gtex.sh 2025-02-26 21:12:09 UTC (rev 74305)
@@ -92,6 +92,6 @@
$RM doc/luatex/gregoriotex//UPGRADE.md
rmdir -p doc/luatex/gregoriotex/ 2> /dev/null || true
-$RM source/luatex/gregoriotex//gregorio-6.1.0-beta2.zip
+$RM source/luatex/gregoriotex//gregorio-6.1.0-rc1.zip
rmdir -p source/luatex/gregoriotex/ 2> /dev/null || true
Deleted: trunk/Master/texmf-dist/source/luatex/gregoriotex/gregorio-6.1.0-beta2.zip
===================================================================
(Binary files differ)
Added: trunk/Master/texmf-dist/source/luatex/gregoriotex/gregorio-6.1.0-rc1.zip
===================================================================
(Binary files differ)
Index: trunk/Master/texmf-dist/source/luatex/gregoriotex/gregorio-6.1.0-rc1.zip
===================================================================
--- trunk/Master/texmf-dist/source/luatex/gregoriotex/gregorio-6.1.0-rc1.zip 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/source/luatex/gregoriotex/gregorio-6.1.0-rc1.zip 2025-02-26 21:12:09 UTC (rev 74305)
Property changes on: trunk/Master/texmf-dist/source/luatex/gregoriotex/gregorio-6.1.0-rc1.zip
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Modified: trunk/Master/texmf-dist/tex/lualatex/gregoriotex/gregoriosyms.sty
===================================================================
--- trunk/Master/texmf-dist/tex/lualatex/gregoriotex/gregoriosyms.sty 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/lualatex/gregoriotex/gregoriosyms.sty 2025-02-26 21:12:09 UTC (rev 74305)
@@ -19,7 +19,7 @@
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{gregoriosyms}
- [2025/02/17 v6.1.0-beta2 GregorioTeX symbols only.]% PARSE_VERSION_DATE_LTX
+ [2025/02/26 v6.1.0-rc1 GregorioTeX symbols only.]% PARSE_VERSION_DATE_LTX
\RequirePackage{iftex}%
\RequireLuaTeX
@@ -41,7 +41,7 @@
% The version of gregorio. All gregoriotex*.tex files must have the same.
% All gtex files must also have the same version.
-\xdef\gre at gregoriotexversion{6.1.0-beta2}% GREGORIO_VERSION - VersionManager.py
+\xdef\gre at gregoriotexversion{6.1.0-rc1}% GREGORIO_VERSION - VersionManager.py
\providecommand{\gre at declarefileversion}[2]{\relax}
Modified: trunk/Master/texmf-dist/tex/lualatex/gregoriotex/gregoriotex.sty
===================================================================
--- trunk/Master/texmf-dist/tex/lualatex/gregoriotex/gregoriotex.sty 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/lualatex/gregoriotex/gregoriotex.sty 2025-02-26 21:12:09 UTC (rev 74305)
@@ -19,7 +19,7 @@
\NeedsTeXFormat{LaTeX2e}%
\ProvidesPackage{gregoriotex}%
- [2025/02/17 v6.1.0-beta2 GregorioTeX system.]% PARSE_VERSION_DATE_LTX
+ [2025/02/26 v6.1.0-rc1 GregorioTeX system.]% PARSE_VERSION_DATE_LTX
\RequirePackage{iftex}%
\RequireLuaTeX
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-chars.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-chars.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-chars.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -17,7 +17,7 @@
% You should have received a copy of the GNU General Public License
% along with Gregorio. If not, see <http://www.gnu.org/licenses/>.
-\gre at declarefileversion{gregoriotex-chars.tex}{6.1.0-beta2}% GREGORIO_VERSION
+\gre at declarefileversion{gregoriotex-chars.tex}{6.1.0-rc1}% GREGORIO_VERSION
\def\gre at char@fuse at punctum@one{\GreFuseTwo{\GreCPLeadingPunctumOne}{\GreCPPunctum}}%
\def\gre at char@fuse at quilisma@one{\GreFuseTwo{\GreCPLeadingQuilismaOne}{\GreCPPunctum}}%
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-common.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-common.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-common.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -17,7 +17,7 @@
% You should have received a copy of the GNU General Public License
% along with Gregorio. If not, see <http://www.gnu.org/licenses/>.
-\gre at declarefileversion{gregoriotex-common.tex}{6.1.0-beta2}% GREGORIO_VERSION
+\gre at declarefileversion{gregoriotex-common.tex}{6.1.0-rc1}% GREGORIO_VERSION
\ifnum\luatexversion<76%
\gre at error{Error: this document must be compiled with LuaTeX (lualatex) 0.76 or later}%
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-gsp-default.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-gsp-default.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-gsp-default.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -20,7 +20,7 @@
% this file contains definitions of spaces and penalties
% version check
-\gre at declarefileversion{gregoriotex-gsp-default.tex}{6.1.0-beta2}% GREGORIO_VERSION
+\gre at declarefileversion{gregoriotex-gsp-default.tex}{6.1.0-rc1}% GREGORIO_VERSION
%% First, the penalties
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-main.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-main.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-main.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -21,7 +21,7 @@
% The version of gregorio. All gregoriotex*.tex files must have the same.
% All gtex files must also have the same version.
-\xdef\gre at gregoriotexversion{6.1.0-beta2}% GREGORIO_VERSION - VersionManager.py
+\xdef\gre at gregoriotexversion{6.1.0-rc1}% GREGORIO_VERSION - VersionManager.py
% first some macros to allow checks for version:
% Tests that all gregoriotex files are of the same version.
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-nabc.lua
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-nabc.lua 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-nabc.lua 2025-02-26 21:12:09 UTC (rev 74305)
@@ -20,7 +20,7 @@
-- this file contains lua functions used by GregorioTeX St. Gall ancient
-- neume support when called with LuaTeX.
--- GREGORIO_VERSION 6.1.0-beta2
+-- GREGORIO_VERSION 6.1.0-rc1
local catcode_at_letter = luatexbase.catcodetables['gre at atletter']
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-nabc.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-nabc.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-nabc.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -19,7 +19,7 @@
% this file contains macros for St. Gall ancient neume support
-\gre at declarefileversion{gregoriotex-nabc.tex}{6.1.0-beta2}% GREGORIO_VERSION
+\gre at declarefileversion{gregoriotex-nabc.tex}{6.1.0-rc1}% GREGORIO_VERSION
\xdef\gre at nabcfontname{gregall}%
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-signs.lua
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-signs.lua 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-signs.lua 2025-02-26 21:12:09 UTC (rev 74305)
@@ -19,7 +19,7 @@
-- this file contains lua functions to support signs used by GregorioTeX.
--- GREGORIO_VERSION 6.1.0-beta2
+-- GREGORIO_VERSION 6.1.0-rc1
local err = gregoriotex.module.err
local warn = gregoriotex.module.warn
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-signs.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-signs.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-signs.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -22,7 +22,7 @@
\def\grebarbracewidth{.58879}%
-\gre at declarefileversion{gregoriotex-signs.tex}{6.1.0-beta2}% GREGORIO_VERSION
+\gre at declarefileversion{gregoriotex-signs.tex}{6.1.0-rc1}% GREGORIO_VERSION
\def\gre at usestylecommon{%
\gre at trace{gre at usestylecommon}%
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-spaces.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-spaces.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-spaces.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -19,7 +19,7 @@
% this file contains definitions of spaces
-\gre at declarefileversion{gregoriotex-spaces.tex}{6.1.0-beta2}% GREGORIO_VERSION
+\gre at declarefileversion{gregoriotex-spaces.tex}{6.1.0-rc1}% GREGORIO_VERSION
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% macros for tuning penalties
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-syllable.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-syllable.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-syllable.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -19,7 +19,7 @@
% this file contains definitions of the glyphs and the syllables
-\gre at declarefileversion{gregoriotex-syllable.tex}{6.1.0-beta2}% GREGORIO_VERSION
+\gre at declarefileversion{gregoriotex-syllable.tex}{6.1.0-rc1}% GREGORIO_VERSION
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% macros for the typesetting of the different glyphs
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-symbols.lua
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-symbols.lua 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-symbols.lua 2025-02-26 21:12:09 UTC (rev 74305)
@@ -19,7 +19,7 @@
-- this file contains lua functions to support signs used by GregorioTeX.
--- GREGORIO_VERSION 6.1.0-beta2
+-- GREGORIO_VERSION 6.1.0-rc1
local err = gregoriotex.module.err
local warn = gregoriotex.module.warn
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-symbols.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-symbols.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex-symbols.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -22,7 +22,7 @@
\ifcsname gregoriotex at symbols@loaded\endcsname\endinput\fi%
\def\gregoriotex at symbols@loaded{}%
-\gre at declarefileversion{gregoriotex-symbols.tex}{6.1.0-beta2}% GREGORIO_VERSION
+\gre at declarefileversion{gregoriotex-symbols.tex}{6.1.0-rc1}% GREGORIO_VERSION
\RequireLuaModule{gregoriotex}%
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex.lua
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex.lua 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex.lua 2025-02-26 21:12:09 UTC (rev 74305)
@@ -24,13 +24,13 @@
gregoriotex = gregoriotex or {}
local gregoriotex = gregoriotex
-local internalversion = '6.1.0-beta2' -- GREGORIO_VERSION (comment used by VersionManager.py)
+local internalversion = '6.1.0-rc1' -- GREGORIO_VERSION (comment used by VersionManager.py)
local err, warn, info, log = luatexbase.provides_module({
name = "gregoriotex",
- version = '6.1.0-beta2', -- GREGORIO_VERSION
+ version = '6.1.0-rc1', -- GREGORIO_VERSION
greinternalversion = internalversion,
- date = "2025/02/17", -- GREGORIO_DATE_LTX
+ date = "2025/02/26", -- GREGORIO_DATE_LTX
description = "GregorioTeX module.",
author = "The Gregorio Project (see CONTRIBUTORS.md)",
copyright = "2008-2025 - The Gregorio Project",
@@ -103,7 +103,7 @@
local base_output_dir = 'tmp-gre'
local function set_base_output_dir(new_dirname)
- base_output_dir = new_dirname
+ base_output_dir = lfs.normalize(new_dirname)
end
local space_below_staff = 5
@@ -139,9 +139,8 @@
local abovelinestext_mark = 2
log("marker whatsit id is %d", marker_whatsit_id)
-local function get_prog_output(cmd, fmt)
- cmd = string.format(cmd, tmpname)
- local rc = os.execute(cmd)
+local function get_prog_output(cmd, tmpname, fmt)
+ local rc = os.spawn(cmd)
local content = nil
if rc == 0 then
local f = io.open(tmpname, 'r');
@@ -163,16 +162,14 @@
local exe_version
-- first look for one with the exact version
- real_gregorio_exe = 'gregorio-6_1_0-beta2' -- FILENAME_VERSION
- local cmd = string.format([[%s -o "%%s" "%s"]], real_gregorio_exe,
- test_snippet_filename)
- exe_version = get_prog_output(cmd, '*line')
+ real_gregorio_exe = 'gregorio-6_1_0-rc1' -- FILENAME_VERSION
+ local cmd = {real_gregorio_exe, '-o', tmpname, test_snippet_filename}
+ exe_version = get_prog_output(cmd, tmpname, '*line')
if not exe_version then
-- look for suffix-less executable
real_gregorio_exe = 'gregorio'
- cmd = string.format([[%s -o "%%s" "%s"]], real_gregorio_exe,
- test_snippet_filename)
- exe_version = get_prog_output(cmd, '*line')
+ cmd = {real_gregorio_exe, '-o', tmpname, test_snippet_filename}
+ exe_version = get_prog_output(cmd, tmpname, '*line')
end
if not exe_version or string.match(exe_version,"%d+%.%d+%.")
~= string.match(internalversion,"%d+%.%d+%.") then
@@ -392,19 +389,18 @@
end
end
end
+
+ local basepath = tex.jobname
if outputdir and lfs.isdir(outputdir) then
- auxname = outputdir..'/'..tex.jobname..'.gaux'
- tmpname = outputdir..'/'..tex.jobname..'.gtmp'
- test_snippet_filename = outputdir..'/'..tex.jobname..'.test.gsnippet'
- snippet_filename = outputdir..'/'..tex.jobname..'.gsnippet'
- snippet_logname = outputdir..'/'..tex.jobname..'.gsniplog'
- else
- auxname = tex.jobname..'.gaux'
- tmpname = tex.jobname..'.gtmp'
- test_snippet_filename = tex.jobname..'.test.gsnippet'
- snippet_filename = tex.jobname..'.gsnippet'
- snippet_logname = tex.jobname..'.gsniplog'
+ basepath = outputdir..'/'..basepath
end
+ basepath = lfs.normalize(basepath)
+
+ auxname = basepath..'.gaux'
+ tmpname = basepath..'.gtmp'
+ test_snippet_filename = basepath..'.test.gsnippet'
+ snippet_filename = basepath..'.gsnippet'
+ snippet_logname = basepath..'.gsniplog'
-- to get latexmk to realize the aux file is a dependency
texio.write_nl('('..auxname..')')
@@ -1088,71 +1084,48 @@
return path
end
--- Recursive directory creation a la mkdir -p. Unlike lfs.mkdir, this will
--- create missing intermediate directories, and will not fail if the
--- destination directory already exists.
--- It assumes that the directory separator is '/' and that the path is valid
--- for the OS it's running on, e.g. no trailing slashes on windows -- it's up
--- to the caller to ensure this!
-function lfs.rmkdir(path)
- path = lfs.normalize(path)
- if lfs.exists(path) then
- return true
- end
- if lfs.dirname(path) == path then
- -- We're being asked to create the root directory!
- return nil,"rmkdir: unable to create root directory"
- end
- local r,err = lfs.rmkdir(lfs.dirname(path))
- if not r then
- return nil,err.." (creating "..path..")"
- end
- return lfs.mkdir(path)
-end
--- end https://github.com/ToxicFrog/luautil/blob/master/lfs.lua
-
-local function clean_old_gtex_files(file_withdir)
- local filename = ""
- local dirpath = ""
- local sep = ""
- local onwindows = os.type == "windows" or
- string.find(os.getenv("PATH"),";",1,true)
- if onwindows then
- sep = "\\"
- else
- sep = "/"
- end
- dirpath = string.match(file_withdir, "(.*)"..sep)
- if dirpath then -- dirpath is nil if current directory
- filename = "^"..file_withdir:match(".*/".."(.*)").."%-%d+_%d+_%d+[-%a%d]*%.gtex$"
- if lfs.exists(dirpath) then
- for a in lfs.dir(dirpath) do
+local function delete_versioned_files(dir, base, ext)
+ -- Assume that dir is either empty (current directory) or ends with separator
+ filename = "^"..base.."%-%d+_%d+_%d+[-%a%d]*%."..ext.."$"
+ if dir ~= "" then
+ if lfs.exists(dir) then
+ for a in lfs.dir(dir) do
+ a = lfs.normalize(a)
if a:match(filename) then
- os.remove(dirpath..sep..a)
+ info("Deleting old file %s", dir..a)
+ os.remove(dir..a)
end
end
end
else
- filename = "^"..file_withdir.."%-%d+_%d+_%d+[-%a%d]*%.gtex$"
for a in lfs.dir(lfs.currentdir()) do
- if a:match(filename) then os.remove(a) end
+ a = lfs.normalize(a)
+ if a:match(filename) then
+ info("Deleting old file %s", a)
+ os.remove(a)
+ end
end
end
end
+function table.extend(x, y)
+ table.move(y, 1, #y, #x+1, x)
+end
+
local function compile_gabc(gabc_file, gtex_file, glog_file, allow_deprecated)
info("compiling the score %s...", gabc_file)
- local extra_args = ''
+ local cmd = {gregorio_exe()}
if tex.count['gre at generate@pointandclick'] == 1 then
- extra_args = extra_args..' -p'
+ table.insert(cmd, '-p')
end
if not allow_deprecated then
- extra_args = extra_args..' -D'
+ table.insert(cmd, '-D')
end
- local cmd = string.format('%s %s -W -o %s -l %s "%s" 2> %s', gregorio_exe(),
- extra_args, gtex_file, glog_file, gabc_file, glog_file)
- res = os.execute(cmd)
+ table.extend(cmd, {'-W', '-o', gtex_file, '-l', glog_file, gabc_file})
+ info("running: %s", table.concat(cmd, ' '))
+ res = os.spawn(cmd)
+
if res == nil then
err("\nSomething went wrong when executing\n '%s'.\n"
.."shell-escape mode may not be activated. Try\n\n"
@@ -1159,50 +1132,44 @@
.."%s --shell-escape %s.tex\n\n"
.."See the documentation of Gregorio or your TeX\n"
.."distribution to automatize it.",
- cmd, tex.formatname, tex.jobname)
+ table.concat(cmd, ' '), tex.formatname, tex.jobname)
elseif res ~= 0 then
- local glog = io.open(glog_file, 'a+')
+ err("\nSomething went wrong when executing\n '%s'",
+ table.concat(cmd, ' '))
+ else
+ -- Open glog_file for writing so that the LuaTeX recorder knows that gregorio wrote to it.
+ local glog = io.open(glog_file, 'a')
if glog == nil then
- err("\n Unable to open %s", glog_file)
+ warn("\n Unable to open %s for writing. If another program depends on %s, latexmk may not recognize the dependency", glog_file, glog_file)
else
- local size = glog:seek('end')
- if size > 0 then
- glog:seek('set')
- local line
- for line in glog:lines() do
- warn(line)
- end
- end
glog:close()
end
- err("\nAn error occured when compiling the score file\n"
- .."'%s' with %s.\nPlease check your score file.", gabc_file,
- gregorio_exe())
- else
- -- The next few lines would open the gtex file for writing so that LuaTeX records the fact that gregorio has written to it
- -- when the -recorder option is used.
- -- However, in restricted \write18 mode, the gtex file might not be writable. Since we're the sole consumer of the gtex file, it should be okay not to record the write.
- local gtex = io.open(gtex_file, 'a')
- if gtex == nil then
- warn("\n Unable to open %s for writing. If another program depends on %s, latexmk may not recognize the dependency.", gtex_file, gtex_file)
- else
- gtex:close()
- end
- local glog = io.open(glog_file, 'a+')
+ -- Copy the contents of glog_file into warnings.
+ glog = io.open(glog_file, 'r')
if glog == nil then
- err("\n Unable to open %s", glog_file)
+ err("\n Unable to open %s for reading", glog_file)
else
- local size = glog:seek('end')
- if size > 0 then
- glog:seek('set')
- local line
- for line in glog:lines() do
- warn(line)
- end
- warn("*** end of warnings for %s ***", gabc_file)
+ for line in glog:lines() do
+ warn(line)
end
glog:close()
end
+
+ if res ~= 0 then
+ err("\nAn error occured when compiling the score file\n"
+ .."'%s' with %s.\nPlease check your score file.", gabc_file,
+ gregorio_exe())
+ else
+ -- The next few lines would open the gtex file for writing so that LuaTeX records the fact that gregorio has written to it
+ -- when the -recorder option is used.
+ -- However, in restricted \write18 mode, the gtex file might not be writable. Since we're the sole consumer of the gtex file, it should be okay not to record the write.
+ local gtex = io.open(gtex_file, 'a')
+ if gtex == nil then
+ warn("\n Unable to open %s for writing. If another program depends on %s, latexmk may not recognize the dependency.", gtex_file, gtex_file)
+ else
+ gtex:close()
+ end
+ end
end
end
@@ -1212,6 +1179,7 @@
gre_input_path = {""}
end
for i,k in pairs(gre_input_path) do
+ k = lfs.normalize(k)
log("Looking in %s", k)
if lfs.isfile(k .. filename) then
result = k..filename
@@ -1237,119 +1205,107 @@
return result
end
-local function include_score(input_file, force_gabccompile, allow_deprecated)
- if string.match(input_file, "[#%%]") then
+local function include_score(gabc_file, force_gabccompile, allow_deprecated)
+ gabc_file = lfs.normalize(gabc_file)
+
+ if string.match(gabc_file, "[#%%]") then
err("GABC filename contains invalid character(s): # %%\n"
- .."Rename the file and retry: %s", input_file)
+ .."Rename the file and retry: %s", gabc_file)
end
- local has_extention = false
- local file_dir,input_name
+ local gabc_dir, base
local extensions = {['gabc']=true, ['gtex']=true, ['tex']=true}
- if extensions[string.match(input_file, "([^%.\\/]*)$")] then
- has_extention = true
- end
- if has_extention then
- file_dir,input_name = string.match(input_file, "(.-)([^\\/]-)%.?[^%.\\/]*$")
+ if extensions[string.match(gabc_file, "([^%./]*)$")] then
+ gabc_dir, base = string.match(gabc_file, "(.-)([^/]-)%.?[^%./]*$")
else
- file_dir,input_name = string.match(input_file, "(.-)([^\\/]*)$")
+ gabc_dir, base = string.match(gabc_file, "(.-)([^/]*)$")
end
+ local base_cleaned = base:gsub("[%s%+%&%*%?$@:;!\"\'`]", "-")
- local cleaned_filename = input_name:gsub("[%s%+%&%*%?$@:;!\"\'`]", "-")
- local gabc_filename = string.format("%s%s.gabc", file_dir, input_name)
- local gabc_file = locate_file(gabc_filename)
- local gtex_filename = string.format("%s%s-%s.gtex", file_dir, cleaned_filename,
- internalversion:gsub("%.", "_"))
- local gtex_file = locate_file(gtex_filename)
- local glog_file = string.format("%s%s-%s.glog", file_dir, cleaned_filename,
- internalversion:gsub("%.", "_"))
- if not gtex_file then
- clean_old_gtex_files(file_dir..cleaned_filename)
- log("The file %s does not exist. Will use gabc file", gtex_filename)
- if gabc_file then
- local gabc = io.open(gabc_file, 'r')
- if gabc == nil then
- err("\n Unable to open %s", gabc_file)
- return
- else
- gabc:close()
+ -- Find gabc file
+ gabc_file = string.format("%s%s.gabc", gabc_dir, base)
+ local gabc_found = locate_file(gabc_file)
+ if gabc_found then
+ gabc_found = lfs.normalize(gabc_found)
+ end
+
+ -- Set up output directory
+ local output_dir = base_output_dir..'/'..gabc_dir
+ output_dir = string.explode(output_dir, '/')
+ for i, _ in ipairs(output_dir) do
+ if output_dir[i] == '..' then output_dir[i] = 'dotdot' end
+ end
+ output_dir = table.concat(output_dir, '/')
+ info('Output directory: %s', output_dir)
+ if not lfs.exists(output_dir) then
+ local ok, message = lfs.mkdirp(output_dir)
+ if not ok then
+ info('Could not create directory %s: %s', output_dir, message)
+ end
+ end
+
+ -- Choose output filenames
+ gtex_file = string.format("%s%s-%s.gtex", output_dir, base_cleaned,
+ internalversion:gsub("%.", "_"))
+ glog_file = string.format("%s%s-%s.glog", output_dir, base_cleaned,
+ internalversion:gsub("%.", "_"))
+
+ -- Decide if we need to recompile
+ local needs_compile = false
+ if gabc_found then
+ if lfs.exists(gtex_file) then
+ local gtex_timestamp = lfs.attributes(gtex_file).modification
+ local gabc_timestamp = lfs.attributes(gabc_found).modification
+ if gtex_timestamp < gabc_timestamp then
+ log("%s has been modified and %s needs to be updated. Recompiling the gabc file", gabc_found, gtex_file)
+ needs_compile = true
end
- local sep = ""
- local onwindows = os.type == "windows" or
- string.find(os.getenv("PATH"),";",1,true)
- if onwindows then
- sep = "\\"
- else
- sep = "/"
- end
- local output_dir = base_output_dir..sep..file_dir
- info(output_dir)
- if not lfs.exists(output_dir) then
- if not lfs.exists(base_output_dir) then
- lfs.mkdir(base_output_dir)
- end
- local err,message = lfs.rmkdir(output_dir)
- if not err then
- info(message)
- end
- end
- gtex_filename = string.format("%s%s-%s.gtex", output_dir, cleaned_filename,
- internalversion:gsub("%.", "_"))
- glog_file = string.format("%s%s-%s.glog", output_dir, cleaned_filename,
- internalversion:gsub("%.", "_"))
- compile_gabc(gabc_file, gtex_filename, glog_file, allow_deprecated)
- gtex_filename = lfs.normalize(gtex_filename)
- tex.print(string.format([[\input %s\relax]], gtex_filename))
- return
else
- err("The file %s does not exist", gabc_filename)
+ log("The file %s does not exist. Compiling gabc file", gtex_file)
+ needs_compile = true
+ end
+ else
+ if lfs.exists(gtex_file) then
+ log("The file %s does not exist. Using gtex file", gabc_file)
+ else
+ err("The file %s does not exist", gabc_file)
return
end
end
- if not gabc_file then
- gtex_file = lfs.normalize(gtex_file)
- tex.print(string.format([[\input %s\relax]], gtex_file))
- return
+ if needs_compile then
+ -- Delete old gtex files.
+ -- Before version 6.1, gtex files were stored in gabc_dir
+ delete_versioned_files(gabc_dir, base_cleaned, 'gtex')
+ delete_versioned_files(gabc_dir, base_cleaned, 'glog')
+ -- Since version 6.1, gtex files are stored in output_dir
+ delete_versioned_files(output_dir, base_cleaned, 'gtex')
+ delete_versioned_files(output_dir, base_cleaned, 'glog')
+
+ local gabc = io.open(gabc_found, 'r')
+ if gabc == nil then
+ err("\n Unable to open %s", gabc_found)
+ return
+ else
+ gabc:close()
+ end
+ compile_gabc(gabc_found, gtex_file, glog_file, allow_deprecated)
end
- local gtex_timestamp = lfs.attributes(gtex_file).modification
- local gabc_timestamp = lfs.attributes(gabc_file).modification
- -- open the gabc file for reading so that LuaTeX records input from it
- -- when the -recorder option is used; do this here so that this happens
- -- on every run
- tex.sprint(catcode_at_letter, string.format(
- [[\openin\gre at read@temp=%s\relax\closein\gre at read@temp]], gabc_file))
- local gabc = io.open(gabc_file, 'r')
- if gabc == nil then
- err("\n Unable to open %s", gabc_file)
- else
- gabc:close()
- end
- if gtex_timestamp < gabc_timestamp then
- log("%s has been modified and %s needs to be updated. Recompiling the gabc file.", gabc_file, gtex_file)
- compile_gabc(gabc_file, gtex_file, glog_file, allow_deprecated)
- elseif force_gabccompile then
- compile_gabc(gabc_file, gtex_file, glog_file, allow_deprecated)
- end
- gtex_file = lfs.normalize(gtex_file)
+
+ -- Input the gtex file
tex.print(string.format([[\input %s\relax]], gtex_file))
- return
end
local function direct_gabc(gabc, header, allow_deprecated)
info('Processing gabc snippet...')
- local deprecated
- if allow_deprecated then
- deprecated = ''
- else
- deprecated = '-D '
- end
local f = io.open(snippet_filename, 'w')
-- trims spaces on both ends (trim6 from http://lua-users.org/wiki/StringTrim)
gabc = gabc:match('^()%s*$') and '' or gabc:match('^%s*(.*%S)')
f:write('name:direct-gabc;\n'..(header or '')..'\n%%\n'..gabc:gsub('\\par', '\n'))
f:close()
- local cmd = string.format([[%s -W %s-o "%%s" -l "%s" "%s"]], gregorio_exe(),
- deprecated, snippet_logname, snippet_filename)
- local content = get_prog_output(cmd, '*a')
+ cmd = {gregorio_exe(), '-W'}
+ if allow_deprecated then table.insert(cmd, '-D') end
+ table.extend(cmd, {'-o', tmpname, '-l', snippet_logname, snippet_filename})
+ info('Running %s', table.concat(cmd, ' '))
+ local content = get_prog_output(cmd, tmpname, '*a')
if content == nil then
err("\nSomething went wrong when executing\n %s\n"
.."shell-escape mode may not be activated. Try\n\n"
Modified: trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex.tex
===================================================================
--- trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex.tex 2025-02-26 15:06:37 UTC (rev 74304)
+++ trunk/Master/texmf-dist/tex/luatex/gregoriotex/gregoriotex.tex 2025-02-26 21:12:09 UTC (rev 74305)
@@ -21,7 +21,7 @@
% This file needs to be marked with the version number. For now I've done this with the following comment, but we should check to see if PlainTeX has something similar to the version declaration of LaTeX and use that if it does.
-% [2025/02/17 v6.1.0-beta2 GregorioTeX system.]% PARSE_VERSION_DATE_LTX
+% [2025/02/26 v6.1.0-rc1 GregorioTeX system.]% PARSE_VERSION_DATE_LTX
\input iftex.sty
\RequireLuaTeX%
More information about the tex-live-commits
mailing list.