mirror of
https://github.com/logos-storage/questionable.git
synced 2026-01-07 08:13:11 +00:00
Fixes for styleCheck:usages (#16)
* Fixes for styleCheck:usages * Bump nim 1.2 in CI
This commit is contained in:
parent
955597a4fd
commit
b0666ba4f1
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@ -7,7 +7,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
nim: [stable, 1.4.8, 1.2.6]
|
nim: [stable, 1.4.8, 1.2.18]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- uses: iffy/install-nim@v3
|
- uses: iffy/install-nim@v3
|
||||||
|
|||||||
@ -1,3 +1,9 @@
|
|||||||
|
--styleCheck:usages
|
||||||
|
if (NimMajor, NimMinor) < (1, 6):
|
||||||
|
--styleCheck:hint
|
||||||
|
else:
|
||||||
|
--styleCheck:error
|
||||||
|
|
||||||
# begin Nimble config (version 1)
|
# begin Nimble config (version 1)
|
||||||
when fileExists("nimble.paths"):
|
when fileExists("nimble.paths"):
|
||||||
include "nimble.paths"
|
include "nimble.paths"
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
import std/options
|
import std/options
|
||||||
|
|
||||||
var captureEnabled {.global, compiletime.}: bool
|
var captureEnabled {.global, compileTime.}: bool
|
||||||
var errorVariable: ptr ref CatchableError
|
var errorVariable: ptr ref CatchableError
|
||||||
|
|
||||||
template captureBindError*(error: var ref CatchableError, expression): auto =
|
template captureBindError*(error: var ref CatchableError, expression): auto =
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
template tryImport(module) = import module
|
template tryImport(module) = import module
|
||||||
|
|
||||||
when compiles tryimport pkg/result:
|
when compiles tryImport pkg/result:
|
||||||
import pkg/result/../results
|
import pkg/result/../results
|
||||||
else:
|
else:
|
||||||
import pkg/stew/results
|
import pkg/stew/results
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user