summary refs log tree commit diff
path: root/pkgs/build-support/fetchgit
diff options
context:
space:
mode:
authorLuflosi <luflosi@luflosi.de>2021-02-03 18:35:42 +0100
committerLuflosi <luflosi@luflosi.de>2021-02-03 18:41:50 +0100
commite238ff073f7cef9766261b6aec6cf98ae33f72b0 (patch)
tree2381335f153eeda3eb9d1898294444008043b717 /pkgs/build-support/fetchgit
parent33b610fa098b47d53aa780fd3285789ada04903c (diff)
downloadnixpkgs-e238ff073f7cef9766261b6aec6cf98ae33f72b0.tar
nixpkgs-e238ff073f7cef9766261b6aec6cf98ae33f72b0.tar.gz
nixpkgs-e238ff073f7cef9766261b6aec6cf98ae33f72b0.tar.bz2
nixpkgs-e238ff073f7cef9766261b6aec6cf98ae33f72b0.tar.lz
nixpkgs-e238ff073f7cef9766261b6aec6cf98ae33f72b0.tar.xz
nixpkgs-e238ff073f7cef9766261b6aec6cf98ae33f72b0.tar.zst
nixpkgs-e238ff073f7cef9766261b6aec6cf98ae33f72b0.zip
fetchgit: escape dot in regex
This regex should match files ending in `.git`, not any character and `git` after that.
Diffstat (limited to 'pkgs/build-support/fetchgit')
-rw-r--r--pkgs/build-support/fetchgit/default.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/pkgs/build-support/fetchgit/default.nix b/pkgs/build-support/fetchgit/default.nix
index df97ef1492d..3222866dc78 100644
--- a/pkgs/build-support/fetchgit/default.nix
+++ b/pkgs/build-support/fetchgit/default.nix
@@ -3,7 +3,7 @@
     inherit (lib) removeSuffix splitString last;
     base = last (splitString ":" (baseNameOf (removeSuffix "/" url)));
 
-    matched = builtins.match "(.*).git" base;
+    matched = builtins.match "(.*)\\.git" base;
 
     short = builtins.substring 0 7 rev;