mirror of
https://github.com/janet-lang/janet
synced 2025-11-19 08:45:11 +00:00
Compare commits
6 Commits
envblock
...
circleci-p
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c3fa24c1e6 | ||
|
|
f1819c916a | ||
|
|
dd14b24d2a | ||
|
|
050d7c12a3 | ||
|
|
7e2c433abc | ||
|
|
6713b23a65 |
14
.circleci/config.yml
Normal file
14
.circleci/config.yml
Normal file
@@ -0,0 +1,14 @@
|
||||
version: 2.1
|
||||
|
||||
orbs:
|
||||
# for later
|
||||
windows: circleci/windows@2.2.0
|
||||
|
||||
jobs:
|
||||
build:
|
||||
macos:
|
||||
xcode: 11.3.0
|
||||
steps:
|
||||
- checkout
|
||||
- run: make
|
||||
- run: make test
|
||||
@@ -1,8 +1,9 @@
|
||||
# Changelog
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
## Unreleased - ???
|
||||
- Fix documentation typos
|
||||
## 1.15.2 - 2021-02-15
|
||||
- Fix bug in windows version of `os/spawn` and `os/execute` with setting environment variables.
|
||||
- Fix documentation typos.
|
||||
- Fix peg integer reading combinators when used with capture tags.
|
||||
|
||||
## 1.15.0 - 2021-02-08
|
||||
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
project('janet', 'c',
|
||||
default_options : ['c_std=c99', 'b_lundef=false', 'default_library=both'],
|
||||
version : '1.15.1')
|
||||
version : '1.15.2')
|
||||
|
||||
# Global settings
|
||||
janet_path = join_paths(get_option('prefix'), get_option('libdir'), 'janet')
|
||||
|
||||
@@ -5,9 +5,9 @@
|
||||
|
||||
#define JANET_VERSION_MAJOR 1
|
||||
#define JANET_VERSION_MINOR 15
|
||||
#define JANET_VERSION_PATCH 1
|
||||
#define JANET_VERSION_EXTRA "-dev"
|
||||
#define JANET_VERSION "1.15.1-dev"
|
||||
#define JANET_VERSION_PATCH 2
|
||||
#define JANET_VERSION_EXTRA ""
|
||||
#define JANET_VERSION "1.15.2"
|
||||
|
||||
/* #define JANET_BUILD "local" */
|
||||
|
||||
|
||||
@@ -210,7 +210,6 @@ static EnvBlock os_execute_env(int32_t argc, const Janet *argv) {
|
||||
janet_buffer_push_bytes(temp, vals, janet_string_length(vals));
|
||||
janet_buffer_push_u8(temp, '\0');
|
||||
}
|
||||
if (temp->count == 0) return NULL;
|
||||
janet_buffer_push_u8(temp, '\0');
|
||||
char *ret = janet_smalloc(temp->count);
|
||||
memcpy(ret, temp->data, temp->count);
|
||||
@@ -250,13 +249,13 @@ static EnvBlock os_execute_env(int32_t argc, const Janet *argv) {
|
||||
static void os_execute_cleanup(EnvBlock envp, const char **child_argv) {
|
||||
#ifdef JANET_WINDOWS
|
||||
(void) child_argv;
|
||||
janet_sfree(envp);
|
||||
if (NULL != envp) janet_sfree(envp);
|
||||
#else
|
||||
janet_sfree((void *)child_argv);
|
||||
if (NULL != envp) {
|
||||
char **envitem = envp;
|
||||
while (*envitem != NULL) {
|
||||
free(*envitem);
|
||||
janet_sfree(*envitem);
|
||||
envitem++;
|
||||
}
|
||||
}
|
||||
@@ -942,7 +941,6 @@ static Janet os_execute_impl(int32_t argc, Janet *argv, int is_spawn) {
|
||||
janet_unlock_environ();
|
||||
}
|
||||
|
||||
/* Wait for child */
|
||||
os_execute_cleanup(envp, child_argv);
|
||||
if (status) {
|
||||
janet_panicf("%p: %s", argv[0], strerror(errno));
|
||||
|
||||
@@ -143,4 +143,7 @@
|
||||
(assert (< 100 1e23) "greater than immediate 1")
|
||||
(assert (< 1000 1e23) "greater than immediate 2")
|
||||
|
||||
# os/execute with environment variables
|
||||
(assert (= 0 (os/execute [(dyn :executable) "-e" "(+ 1 2 3)"] :pe {"HELLO" "WORLD"})) "os/execute with env")
|
||||
|
||||
(end-suite)
|
||||
|
||||
Reference in New Issue
Block a user