-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure dashboard displays even when there's no remote_url (#10)
* Return cwd if unable to extract remote_url When remote `origin` doesn't exist or no remote available. This ensure dashboard displays instead of showing up blank * Adjust the remote url pattern matching expression * Remove a redundant matching pattern * Fix: nvim_get_option is deprecated * Revert "Remove a redundant matching pattern" * Display dashboard even when there is no commit instead of showing blank page
- Loading branch information
Showing
4 changed files
with
20 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,6 +38,22 @@ describe("git", function() | |
assert(repo_with_owner == "juansalvatore/git-dashboard-nvim") | ||
end) | ||
|
||
it("should parse repo with extra dot in name", function() | ||
local git = require("git-dashboard-nvim.git") | ||
local repo_with_owner = git._parse_repo_and_owner("[email protected]:csessh/.dotfiles.git") | ||
|
||
assert(repo_with_owner ~= nil) | ||
assert(repo_with_owner == "csessh/.dotfiles") | ||
end) | ||
|
||
it("should parse repo with extra dot in name", function() | ||
local git = require("git-dashboard-nvim.git") | ||
local repo_with_owner = git._parse_repo_and_owner("[email protected]:csessh/test.nvim.git") | ||
|
||
assert(repo_with_owner ~= nil) | ||
assert(repo_with_owner == "csessh/test.nvim") | ||
end) | ||
|
||
it("should parse repo with owner from github ssh url without .git", function() | ||
local git = require("git-dashboard-nvim.git") | ||
local repo_with_owner = | ||
|