Commit Graph

711 Commits (0fd4c699ddb2063a58584ac737475d44c0d16711)

Author SHA1 Message Date
Alexander Medvednikov 36ec47cd20 all: replace "NB:" with "Note:" (docs/comments) 2022-03-06 20:01:22 +03:00
Delyan Angelov f2e5bb447e
os: remove dead code 2022-02-21 22:57:24 +02:00
Delyan Angelov bad30bdd79
os: allow using XDG_CACHE_HOME for choosing the folder returned by `os.cache_dir()` on windows too 2022-02-13 11:18:51 +02:00
Tim Basel 9d0a5942ac
builtin: change IError `msg` and `code` to methods + fix vlib, add a deprecation notice for the old usages (#13041) 2022-02-11 15:52:33 +02:00
Juergen Donnerstag 654bc49d3c
os: implement win_read_string on os.Process (#13428) 2022-02-11 13:02:00 +02:00
Tarcisio Gruppi 51513ae19a
vfmt: keep file permissions with -w on !windows (#13334) 2022-02-01 14:49:06 +02:00
Merlin Diavova f3683b7cdc
os: add an .exit_code field to os.Command (#13321)
* Added os.Command.exit_code

* vfmt vlib/os/os_test.v

* extract os.Command to os.v, add a dummy panicing implementation on windows, just for parity, fix os_test.v on macos, skip test_command on windows.

Co-authored-by: Merlin Diavova <md@merlindiaova.org>
Co-authored-by: Delyan Angelov <delian66@gmail.com>
2022-01-30 00:44:52 +02:00
Subhomoy Haldar fe77e64b3e
os: remove trim_space() in os.execute() on windows, to make implementations consistent (#13272) 2022-01-25 14:09:56 +02:00
Delyan Angelov 34f0d442df
ci: separate other_ci.yml and paths_ci.yml; simplify make.bat (#13254) 2022-01-23 12:50:19 +02:00
Delyan Angelov fa6f7d4c83
os: add os.quoted_path/1, use it consistently for running V itself 2022-01-22 21:13:28 +02:00
playX 7fe62a8b3e
js,os: fix `return` in `or` blocks; Properly get path_delimiter and path_separator in JS (#13179) 2022-01-15 09:55:03 +02:00
Larpon 7fbd856bf8
os: add font module, move from gg (#13144) 2022-01-13 12:16:18 +02:00
Larpon 17911432b9
android: fix and test compilation to raw Android C code (#13080) 2022-01-07 16:57:05 +02:00
jeffmikels a60b381d5e
docs: adding skeleton README.md files for all vlib modules (#13034) 2022-01-05 18:06:08 +02:00
Alexander Medvednikov 59ed4be49a all: update copyright year 2022-01-04 12:21:12 +03:00
playX a2468e1e0c
js,os: fix integer arithmetic; add Process.close() and os.is_readable() for VJS; Make tetris run on JS backend (#12940) 2021-12-23 11:36:42 +02:00
playX 5f0160bf11
js,gg: more work on porting gg to JS backend (#12903) 2021-12-20 16:18:21 +03:00
playX cb4c67588c
os: add support for signal handling on JS backend (#12818) 2021-12-13 20:18:12 +02:00
playX 0da7e2f8ab
js: make vlib/v/util compile on JS backend (#12660) 2021-12-03 12:25:36 +02:00
Delyan Angelov 5e8288528a
ci: fix `v -b js vlib/builtin/js/array_test.js.v` 2021-11-22 15:11:33 +02:00
Delyan Angelov 6a252ed015
os: implement a JS version of os.join_path_single too 2021-11-22 15:03:05 +02:00
Delyan Angelov 7a0dc60d04
os: re-add the leak in os.join_path (the `os.join_path(x, ...arr)` case should be handled by V). Add a memleak free os.join_path_single version. 2021-11-22 14:40:55 +02:00
Delyan Angelov c3b8e5e181 ci: fix compilation on FreeBSD 2021-11-22 09:32:13 +00:00
Delyan Angelov 84aa05f8fb
ci: fix macos build 2021-11-22 11:07:26 +02:00
Delyan Angelov fe48380e85
os: cleanup; ci: fix a segfault in the tcc32 job when calling pref.vexe_path() -> os.real_path(os.executable()) 2021-11-22 10:32:10 +02:00
Delyan Angelov e77a11001e
os: make init_os_args_wide (windows), more simillar to the current init_os_args (unix) 2021-11-21 23:04:30 +02:00
Delyan Angelov c7bd74e0f8
ci: fix build, remove `[manualfree]` from os.vmodules_paths for now 2021-11-21 22:34:38 +02:00
Delyan Angelov 1aaac13a60
cgen: make `os` less special, fix an -autofree leak on just `import os`
* Improve documentation of v.util.Surrounder

* Remove `os` from the list of "no auto free" `builtin` mods

* Fix -autofree freeing of `const x = []string{}`.

* Add a valgrind regression test.

* Implement os.getenv_opt in vlib/os/environment.js.v too.
2021-11-21 21:50:10 +02:00
Delyan Angelov 24ffc1ffb2
os: fix os.rmdir_all for folders with recursive symlinks 2021-11-20 10:28:12 +02:00
Delyan Angelov 762a7fde2a
os: add os.getenv_opt/1 2021-11-19 17:47:45 +02:00
Delyan Angelov 50a608aab3
os: remove unnecessary heap allocation from os.execute 2021-11-12 11:45:37 +02:00
Delyan Angelov c6b8b0bb0a
ci: make test_execute in os_test.v more robust 2021-11-12 11:24:37 +02:00
Delyan Angelov fcecf527ec
ci: fix failing os_test.v on the CI 2021-11-12 10:27:35 +02:00
Delyan Angelov 20d63de136
os: fix os.execute for command output that contains 0 bytes 2021-11-12 09:39:15 +02:00
Delyan Angelov d1acca3e52
ci: fix `./v -cg -cstrict -o v cmd/v` job failures for clang 2021-10-29 17:21:53 +03:00
Delyan Angelov 71392111f8
ci: fix cross compilation of vc/v.c 2021-10-29 17:12:05 +03:00
Delyan Angelov b86c79329b
os, builtin: reduce leaks without -autofree 2021-10-29 15:49:30 +03:00
Delyan Angelov bb71089b70
os: make the os_test.v functions more robust on windows (normalise the returned paths before comparing them) 2021-10-24 19:54:00 +03:00
Delyan Angelov e99b699ac6
os: make os.mkdir_all more robust (honor / on windows too), add a test for it 2021-10-24 19:16:46 +03:00
Delyan Angelov f34daf9ff4
os: add os.walk_with_context/3 and a test for it 2021-10-24 19:12:14 +03:00
Delyan Angelov e34046a0e1
os: remove `pub` from impl_walk_ext 2021-10-24 18:48:54 +03:00
Delyan Angelov d1c4b470bc
os: make os.ls('') return an error, make os.walk_ext more memory efficient on deep hierarchies, add tests for os.walk_ext 2021-10-24 18:44:13 +03:00
playX 864d6eae6b
js: codegen & vlib fixes, replace the Game of Life CLI example (#12272) 2021-10-22 22:03:19 +03:00
Delyan Angelov eed94c727c
os: move C struct declarations in their own _default.c.v files (#12268) 2021-10-22 17:08:08 +03:00
czkz 5607224be6
docs: improve os.ProcessState markdown rendering (#12245) 2021-10-21 11:19:01 +03:00
playX 57c79770b3
js: port more methods (os, builtin) (#12238) 2021-10-20 16:02:21 +03:00
playX c1aa782a6c
js,checker: fix some modules build for `v -b js self`, fix `or block` check in ast.CallExpr (#12231) 2021-10-19 12:11:54 +03:00
playX d373eba79b
js: implement more functions for JS backend (#12167) 2021-10-13 09:40:14 +03:00
Alexander Ivanov 0386f2bbea
checker: add an interface check for mutability, fixes #1081, fixes #7038 (#11963) 2021-10-11 15:41:31 +03:00
Delyan Angelov 5bc8b4dadb
os: implement support for VOPEN_URI_CMD env override for os.open_uri 2021-10-06 06:33:04 +03:00