Clear unused symbols warnings
Unused functions and variables are removed from the Nimble's source code. Resolves #680
This commit is contained in:
parent
db018f235b
commit
6e5761b192
3 changed files with 0 additions and 28 deletions
|
|
@ -10,13 +10,6 @@ type
|
||||||
DownloadMethod* {.pure.} = enum
|
DownloadMethod* {.pure.} = enum
|
||||||
git = "git", hg = "hg"
|
git = "git", hg = "hg"
|
||||||
|
|
||||||
proc getSpecificDir(meth: DownloadMethod): string =
|
|
||||||
case meth
|
|
||||||
of DownloadMethod.git:
|
|
||||||
".git"
|
|
||||||
of DownloadMethod.hg:
|
|
||||||
".hg"
|
|
||||||
|
|
||||||
proc doCheckout(meth: DownloadMethod, downloadDir, branch: string) =
|
proc doCheckout(meth: DownloadMethod, downloadDir, branch: string) =
|
||||||
case meth
|
case meth
|
||||||
of DownloadMethod.git:
|
of DownloadMethod.git:
|
||||||
|
|
@ -30,19 +23,6 @@ proc doCheckout(meth: DownloadMethod, downloadDir, branch: string) =
|
||||||
cd downloadDir:
|
cd downloadDir:
|
||||||
doCmd("hg checkout " & branch)
|
doCmd("hg checkout " & branch)
|
||||||
|
|
||||||
proc doPull(meth: DownloadMethod, downloadDir: string) =
|
|
||||||
case meth
|
|
||||||
of DownloadMethod.git:
|
|
||||||
doCheckout(meth, downloadDir, "")
|
|
||||||
cd downloadDir:
|
|
||||||
doCmd("git pull")
|
|
||||||
if existsFile(".gitmodules"):
|
|
||||||
doCmd("git submodule update")
|
|
||||||
of DownloadMethod.hg:
|
|
||||||
doCheckout(meth, downloadDir, "default")
|
|
||||||
cd downloadDir:
|
|
||||||
doCmd("hg pull")
|
|
||||||
|
|
||||||
proc doClone(meth: DownloadMethod, url, downloadDir: string, branch = "",
|
proc doClone(meth: DownloadMethod, url, downloadDir: string, branch = "",
|
||||||
onlyTip = true) =
|
onlyTip = true) =
|
||||||
case meth
|
case meth
|
||||||
|
|
|
||||||
|
|
@ -375,8 +375,6 @@ proc execScript(scriptName: string, flags: Flags, options: Options): PSym =
|
||||||
"more info."
|
"more info."
|
||||||
raiseNimbleError(msg, hint)
|
raiseNimbleError(msg, hint)
|
||||||
|
|
||||||
let pkgName = scriptName.splitFile.name
|
|
||||||
|
|
||||||
# Ensure that "nimblepkg/nimscriptapi" is in the PATH.
|
# Ensure that "nimblepkg/nimscriptapi" is in the PATH.
|
||||||
block:
|
block:
|
||||||
let t = getNimbleUserTempDir() / "nimblecache"
|
let t = getNimbleUserTempDir() / "nimblecache"
|
||||||
|
|
@ -692,11 +690,6 @@ proc execHook*(scriptName, actionName: string, before: bool,
|
||||||
|
|
||||||
cleanup()
|
cleanup()
|
||||||
|
|
||||||
proc getNimScriptCommand(): string =
|
|
||||||
when declared(NimCompilerApiVersion):
|
|
||||||
let conf = graph.config
|
|
||||||
nimCommand()
|
|
||||||
|
|
||||||
proc setNimScriptCommand(command: string) =
|
proc setNimScriptCommand(command: string) =
|
||||||
when declared(NimCompilerApiVersion):
|
when declared(NimCompilerApiVersion):
|
||||||
let conf = graph.config
|
let conf = graph.config
|
||||||
|
|
|
||||||
|
|
@ -310,7 +310,6 @@ proc findNimbleFile*(dir: string; error: bool): string =
|
||||||
|
|
||||||
if result.splitFile.ext == ".nimble-link":
|
if result.splitFile.ext == ".nimble-link":
|
||||||
# Return the path of the real .nimble file.
|
# Return the path of the real .nimble file.
|
||||||
let nimbleLinkPath = result
|
|
||||||
result = readNimbleLink(result).nimbleFilePath
|
result = readNimbleLink(result).nimbleFilePath
|
||||||
if not fileExists(result):
|
if not fileExists(result):
|
||||||
let msg = "The .nimble-link file is pointing to a missing file: " & result
|
let msg = "The .nimble-link file is pointing to a missing file: " & result
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue