Skip to content

Commit

Permalink
nix: add postgrest-ctags command
Browse files Browse the repository at this point in the history
Generates ctags for Haskell and Python code.
  • Loading branch information
steve-chavez committed May 8, 2024
1 parent 1b584f7 commit f9e9740
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion nix/tools/devTools.nix
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
, style
, tests
, withTools
, haskellPackages
, ctags
}:
let
watch =
Expand Down Expand Up @@ -292,7 +294,7 @@ let
parallelCurl =
checkedShellScript
{
name = "parallel-curl";
name = "postgrest-parallel-curl";
docs = "wrapper for using <num> parallel curl requests on the same <host>";
args = [
"ARG_POSITIONAL_SINGLE([num], [number of parallel requests])"
Expand All @@ -314,6 +316,17 @@ let
eval "$curl_command"
'';

genCtags =
checkedShellScript
{
name = "postgrest-ctags";
docs = "Generate ctags for Haskell and Python code";
workingDir = "/";
}
''
${ctags}/bin/ctags -a -R --fields=+l --languages=python --python-kinds=-iv -f ./tags test/io/
${haskellPackages.hasktags}/bin/hasktags -a -R -c -f ./tags .
'';
in
buildToolbox
{
Expand All @@ -327,6 +340,7 @@ buildToolbox
hsieGraphSymbols
hsieMinimalImports
parallelCurl
genCtags
pushCachix
watch;
};
Expand Down

0 comments on commit f9e9740

Please sign in to comment.