Skip to content

Commit

Permalink
Merge branch 'master' into bug/misaligned-help
Browse files Browse the repository at this point in the history
  • Loading branch information
etan-status committed Feb 20, 2024
2 parents 14d382a + 57ff0b8 commit 5b7c719
Show file tree
Hide file tree
Showing 31 changed files with 517 additions and 655 deletions.
18 changes: 7 additions & 11 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
cpu: amd64
#- os: windows
#cpu: i386
branch: [version-1-2, version-1-4, version-1-6, devel]
branch: [version-1-6, version-2-0, devel]
include:
- target:
os: linux
Expand All @@ -50,7 +50,7 @@ jobs:
continue-on-error: ${{ matrix.branch == 'devel' }}
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Install build dependencies (Linux i386)
if: runner.os == 'Linux' && matrix.target.cpu == 'i386'
Expand Down Expand Up @@ -96,7 +96,7 @@ jobs:
- name: Restore Nim DLLs dependencies (Windows) from cache
if: runner.os == 'Windows'
id: windows-dlls-cache
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: external/dlls-${{ matrix.target.cpu }}
key: 'dlls-${{ matrix.target.cpu }}'
Expand Down Expand Up @@ -158,12 +158,8 @@ jobs:
nimble install -y --depsOnly
nimble install -y toml_serialization json_serialization unittest2
rm -f nimble.lock
env NIMFLAGS="${NIMFLAGS} --gc:refc" nimble test
let "linux32= "${{ matrix.target.os }}" == "linux" && "${{ matrix.target.cpu }}" == "i386""
if [[ "${{ matrix.branch }}" == "devel" && "$linux32" == 0 ]]; then
echo -e "\nTesting with '--gc:orc':\n"
if env NIMFLAGS="${NIMFLAGS} --gc:orc" nimble test; then
echo "Nim devel with --gc:orc works again! Please remove this check in ci.yml"
false
fi
env NIMFLAGS="${NIMFLAGS} --mm:refc" nimble test
if [[ ${{matrix.branch}} == "devel" ]]; then
echo -e "\nTesting with '--mm:orc':\n"
env NIMFLAGS="${NIMFLAGS} --mm:orc" nimble test
fi
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
nim-confutils
=============

[![Build Status](https://travis-ci.org/status-im/nim-confutils.svg?branch=master)](https://travis-ci.org/status-im/nim-confutils)
[![License: Apache](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
![Github action](https://github.com/status-im/nim-confutils/workflows/CI/badge.svg)
Expand Down Expand Up @@ -426,8 +425,12 @@ variables. The default format is called `CmdLineFormat` and it uses the
same `parseCmdArg` calls responsible for parsing the command-line.

The names of the environment variables are prefixed by the name of the
program by default. They are matched in case-insensitive fashion and
certain characters such as `-` and `_` are ignored.
program by default and joined with the name of command line option, which is
uppercased and characters `-` and spaces are replaced with underscore:

```nim
let env_variable_name = &"{prefix}_{key}".toUpperAscii.multiReplace(("-", "_"), (" ", "_"))
```

#### `configFileEnumerator`

Expand Down
9 changes: 9 additions & 0 deletions config.nims
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
# confutils
# Copyright (c) 2018-2024 Status Research & Development GmbH
# Licensed under either of
# * Apache License, version 2.0, ([LICENSE-APACHE](LICENSE-APACHE))
# * MIT license ([LICENSE-MIT](LICENSE-MIT))
# at your option.
# This file may not be copied, modified, or distributed except according to
# those terms.

# begin Nimble config (version 1)
when fileExists("nimble.paths"):
include "nimble.paths"
Expand Down
Loading

0 comments on commit 5b7c719

Please sign in to comment.