Skip to content

Commit

Permalink
feat(#133): url-format (#134)
Browse files Browse the repository at this point in the history
  • Loading branch information
barrett-ruth authored Jan 27, 2023
1 parent 6506548 commit 540642d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lua/paq.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ local cfg = {
path = vim.fn.stdpath("data") .. "/site/pack/paqs/",
opt = false,
verbose = false,
url_format = 'https://github.com/%s.git'
}
local logpath = vim.fn.has("nvim-0.8") == 1 and vim.fn.stdpath("log") or vim.fn.stdpath("cache")
local logfile = logpath .. "/paq.log"
Expand Down Expand Up @@ -287,7 +288,7 @@ local function register(args)
status = "listed", -- TODO: should probably merge this with `exists` in the future...
pin = args.pin,
run = args.run,
url = args.url or "https://github.com/" .. args[1] .. ".git",
url = args.url or string.format(cfg.url_format, args[1]),
}
end

Expand Down

0 comments on commit 540642d

Please sign in to comment.