866 Commits

Author SHA1 Message Date
Delyan Angelov
50c22b5a12
os: implement os.fd_is_pending/1, os.Process.pipe_read/1, os.Process.is_pending/1 (#19787) 2023-11-07 13:47:25 +02:00
l-m
f82529e020
os: add os.page_size() (#19770) 2023-11-05 13:35:28 +02:00
Turiiya
fbefe6858b
os: mention that execute_opt error contains commands output (#19742) 2023-11-03 13:28:42 +02:00
Turiiya
c82c760df7
os: add a new function execute_opt (#19723) 2023-11-01 13:17:33 +02:00
Turiiya
e465f7490c
tests: cleanup legacy temp path (#19716) 2023-10-31 15:16:19 +02:00
Delyan Angelov
1b2d947fc0 ci: fix bootstrapping of signal_default.c.v on macos 2023-10-25 22:26:52 +03:00
shove
8394b358d8
os: add a convenient way to ignore certain system signals (#19639) 2023-10-25 17:15:26 +03:00
Larpon
95509cf8fb
all: make all struct C.XYZ -> pub struct C.XYZ (#19651) 2023-10-25 15:01:50 +03:00
BigBlack
714a64daa0
os: fix os.ls(folder) on windows, when a protected folder can not be opened (#19647) 2023-10-25 11:21:58 +03:00
Alexander Medvednikov
b39b0927d1
Revert "os: add a convenient way to ignore certain system signals (#19632)" (#19637) 2023-10-24 03:06:57 +03:00
shove
0c92c31406
os: add a convenient way to ignore certain system signals (#19632) 2023-10-23 23:48:39 +03:00
Turiiya
9051ac8921
all: fix typos (#19634) 2023-10-23 21:21:15 +03:00
Delyan Angelov
eb82a72012
ci: vfmt vlib/os/process_windows.c.v and vlib/os/os.c.v 2023-10-16 01:48:35 +03:00
Delyan Angelov
f54f156d25 clipboard: fix v -cstrict -cc gcc vlib/clipboard/clipboard_test.v 2023-10-15 21:21:29 +03:00
Alexander Medvednikov
545ee1ae23 checker: stricter rules for C types; C aliases; sokol fixes 2023-10-14 18:31:44 +03:00
Delyan Angelov
121fa0e92d
term.ui,os.notify: fix .ctrl being stuck in examples/term.ui/event_viewer.v (regression happened in e9a3817a from 2023-02-20) 2023-10-09 14:25:44 +03:00
Spydr
6d1558b006
native, builtin, ast: handle ast.HashStmt correctly and reduce macro usage in builtin (#19498) 2023-10-04 16:42:15 +03:00
Delyan Angelov
24278d82ba
os, v.builder: show more details, when a program ran by v run file.v, exits by a signal (fix #19412) (#19471) 2023-09-29 22:02:59 +03:00
Slashscreen
33754f43fa
all: support -os plan9, $if plan9 {, and _plan9.c.v (stage 1 for plan9) (#19389) 2023-09-20 07:27:30 +03:00
Delyan Angelov
7ffa8c13bf
vlib: remove functions and fields, deprecated before 2023-03-20
* remove []int.reduce in favour of arrays.fold
  * remove datatypes.Set.equal in favour of datatypes.Set.==
  * remove datatypes.Set.difference in favour of datatypes.Set.-
  * remove gg.Context.set_cfg in favour of gg.Context.set_text_cfg
  * remove gg.Context.timage_pip in favour of gg.Context.pipeline.alpha
  * remove os.is_writable_folder in favour of os.ensure_folder_is_writable

  Discovered with `v run cmd/tools/show_ancient_deprecations.v 180`
2023-09-16 17:16:54 +03:00
yuyi
55ca8d8d8e
fmt: align the custom values of the enum fields (#19331) 2023-09-12 14:44:38 +03:00
Alexander Medvednikov
d3e950b3a9 checker: more line-info logic 2023-09-11 01:40:34 +03:00
Alexander Medvednikov
b9a233b1a0 checker: more line-info logic 2023-09-11 01:38:09 +03:00
Kim Shrier
b4d0e12c4c
os: include sys/sysctl.h on FreeBSD to avoid implicit definition of sysctl function (#19293) 2023-09-07 16:08:18 +03:00
yuyi
18e60e77de
fmt: remove inline comments (#19263) 2023-09-03 23:51:56 +03:00
Turiiya
0450a933b9
os: update TOCTOU example in readme, to improve readability of the module docs on mobile (#19255) 2023-09-01 16:09:04 +03:00
Turiiya
f755118e7c
vlib: update doc comments (#19231) 2023-08-30 08:50:00 +03:00
Turiiya
981ff192e4
os: update doc comment for input_opt return (#19223) 2023-08-27 13:40:21 +03:00
Delyan Angelov
9e0c2943e9
os: fix os.execute('x 2> stderr.txt') on windows (#19155) 2023-08-17 10:39:31 +03:00
Delyan Angelov
eef9b5f168
builtin,os: fix compiling V programs with latest clang 16 on windows (clang 16 is stricter than clang 14) (#19095) 2023-08-09 15:04:44 +03:00
shove
320057df1c
os.notify: remove the meaningless [noinit] attribute of the notifier (#19075) 2023-08-07 09:19:54 +03:00
shove
301320f4b0
os.notify: implement the kqueue backend for notify.FdNotifier (#19057) 2023-08-05 07:11:07 +03:00
Delyan Angelov
32114a679a
os,term.termios: add termios.set_state/2, state.disable_echo/0, use them in os.input_password, to fix v -os wasm32_emscripten examples/2048/ 2023-07-31 10:28:45 +03:00
Delyan Angelov
4c9c515f8b
parser: remove hardcoded check for function calls for C.stat, C.sigaction, etc (#18535) 2023-06-24 08:03:12 +03:00
yuyi
caee3935a5
os: fix truncate() on windows (#18262) 2023-05-25 14:37:53 +03:00
yuyi
190f5c69ea
os: fix open_file() on windows (fix #18245) (#18253) 2023-05-25 02:50:52 +02:00
Jacques Supcik
a82fc5bea0
os: make SignalHandler public (#18115) 2023-05-06 14:59:06 +03:00
Felipe Pena
13b4cd9d58
os: fix memleak from getline on Linux (#18022) 2023-04-26 22:02:09 +03:00
Delyan Angelov
c6947fde57
os: implement Process.set_work_folder/0 to set the initial working folder of the new child process (#17946) 2023-04-13 14:48:32 +03:00
Swastik Baranwal
3d99f1f2c2
checker: disallow struct int to ptr outside unsafe (#17923) 2023-04-13 07:38:21 +02:00
Thomas Mangin
580d9cedc7
termios: new termios module (#17792)
* termio: new termio module

move the tcgetattr and tcsetattr functions in a new termio module.
The code needed refactoring as different OS have different fields
size, position and number for the C.termios structure, which
could not be correctly expressed consitently otherwise.

It has the positive side effect to reduce the number of unsafe calls.
New testing code was also added for the readline module as it is
relying of the feature.

* apply 2023 copyright to the new files too
2023-03-30 08:58:52 +03:00
Alexander Medvednikov
6756d28595 all: 2023 copyright 2023-03-28 22:55:57 +02:00
d3c0d3d.exe
54a1b66b94
os: add create_no_window parameter to Process (#17726) 2023-03-21 11:24:40 +02:00
Delyan Angelov
daa9034583
os: return the long path for os.temp_dir() on windows, even for folders like c:\someth~1 (#17623) 2023-03-14 00:51:52 +02:00
Thomas Mangin
0bd094292f
v: add support for _qnx.c.v overriding _default.c.v (#17611) 2023-03-12 19:48:36 +02:00
Ikko Eltociear Ashimine
784592af83
os: fix typo in os.v (#17519) 2023-03-07 08:30:37 +01:00
yuyi
17000ef7b6
checker: check option fn returning error (fix #17423) (#17438) 2023-03-02 15:49:50 +02:00
Haren S
acfd21e4e0
os: add #include <sys/types.h> to debugger_darwin.c.v, to fix bootstrapping on macOS <= 11 (#17446) 2023-03-01 00:06:12 +02:00
l-m
0625caad56
wasm: add a webassembly compiler backend, based on using binaryen (#17368) 2023-02-28 23:58:53 +02:00
paul-elesin
15cb18cbd2
os: make hostname and loginname functions return Result (#17414) 2023-02-27 05:21:23 +03:00