ae91cbe6cc
GitOrigin-RevId: 536fe36e23ab0fc8b7f35c24603422eee9fc17a2
10 lines
336 B
Nix
10 lines
336 B
Nix
{ lib }:
|
|
{
|
|
/* Returns the Agda interface file to a given Agda file.
|
|
*
|
|
* Examples:
|
|
* interfaceFile "Everything.agda" == "Everything.agdai"
|
|
* interfaceFile "src/Everything.lagda.tex" == "src/Everything.agdai"
|
|
*/
|
|
interfaceFile = agdaFile: lib.head (builtins.match ''(.*\.)l?agda(\.(md|org|rst|tex))?'' agdaFile) + "agdai";
|
|
}
|