Commit Graph

307 Commits (ada064d9c3d0216c625624387a44234e5ad6ea9f)

Author SHA1 Message Date
John Benediktsson ca1612cc57 io: fix for win32-error not throwing on zero. 2020-01-06 14:20:15 -08:00
Alexander Iljin 3733b13daf Replace "win32-error-string throw" with windows-error instance throwing
Remove win32-error-string, because there was only one place it was used in.
2020-01-06 13:18:33 -08:00
Alexander Iljin 563a3b1a47 Replace "n>win32-error-string throw" with windows-error instance throwing 2020-01-06 13:18:33 -08:00
Alexander Iljin 135390968b Delete throw-win32-error, replace with win32-error calls 2020-01-06 13:18:33 -08:00
Alexander Iljin 407c7bc216 io.files.windows: replace "-1 <alien>" with INVALID_HANDLE_VALUE 2020-01-06 13:18:33 -08:00
Alexander Iljin 294be2cca3 Replace inline INVALID_HANDLE_VALUE checks with check-invalid-handle calls
On error find-first-file will now throw a windows-error instance instead of
a string.
2020-01-06 13:18:33 -08:00
Doug Coleman f9c90583d0 io.files.info: Fix linux file-system-info recursion 2020-01-05 13:27:22 -06:00
Doug Coleman 9beeedfe18 io.files.info: Fix find-mount-point. 2020-01-04 13:33:45 -06:00
Doug Coleman 4da6f51c91 io.files.info: fix circularity regression in file-systems on linux 2020-01-04 09:07:32 -06:00
Doug Coleman 16442c27ac io: Fix word to find disk space if a file is missing.
Add canonicalize-drive because Windows likes C: instead of c:.

Add >windows-path for path string comparison.

Add canonicalize-path-full for fixing the path, drive, and / to \\ on
Windows.
2020-01-03 16:30:00 -06:00
Doug Coleman 75e98b4bc3 Revert "Replace inline INVALID_HANDLE_VALUE checks with check-invalid-handle calls"
This reverts commit 1e61dbfd2a.
2020-01-03 13:04:29 -06:00
Doug Coleman 8a3b7cbd18 Revert "io.files.windows: replace "-1 <alien>" with INVALID_HANDLE_VALUE"
This reverts commit a6f0b74f03.
2020-01-03 13:04:11 -06:00
Doug Coleman d9f1093cf8 Revert "Delete throw-win32-error, replace with win32-error calls"
This reverts commit e1be081ec9.
2020-01-03 13:04:01 -06:00
Doug Coleman c308d794db Revert "Replace "n>win32-error-string throw" with windows-error instance throwing"
This reverts commit 70d08ce743.
2020-01-03 13:03:52 -06:00
Doug Coleman 7f395ba7f0 Revert "Replace "win32-error-string throw" with windows-error instance throwing"
This reverts commit 2dfb3b3a73.
2020-01-03 13:03:10 -06:00
Doug Coleman 16c153411d io: Trim using lists. 2020-01-03 12:42:11 -06:00
Doug Coleman 3419d34cbf mason.disk: Better handling of free disk space.
- Works if the build directory does not exist, assuming it would be created on the root disk containing the path of the first existing parent directory
- Space calculation is wrong, we should be using the available space
- MB is GB, comment was wrong
- Call find-mount-point-info to get the real disk mount point even if the dir does not exist
2020-01-03 11:10:53 -06:00
Alexander Iljin 2dfb3b3a73 Replace "win32-error-string throw" with windows-error instance throwing
Remove win32-error-string, because there was only one place it was used in.
2019-11-25 07:06:59 -08:00
Alexander Iljin 70d08ce743 Replace "n>win32-error-string throw" with windows-error instance throwing 2019-11-25 07:06:59 -08:00
Alexander Iljin e1be081ec9 Delete throw-win32-error, replace with win32-error calls 2019-11-25 07:06:59 -08:00
Alexander Iljin a6f0b74f03 io.files.windows: replace "-1 <alien>" with INVALID_HANDLE_VALUE 2019-11-25 07:06:59 -08:00
Alexander Iljin 1e61dbfd2a Replace inline INVALID_HANDLE_VALUE checks with check-invalid-handle calls
On error find-first-file will now throw a windows-error instance instead of
a string.
2019-11-25 07:06:59 -08:00
Alexander Iljin 0007789795 continuations[-docs]: add the finally word 2019-04-22 21:57:51 -07:00
Doug Coleman 4df7773a58 io.files.windows: Reloading io.pathnames overwrites these two object
methods.

Make them windows methods instead.
2019-03-17 10:56:57 -05:00
Jack Lucas 3154242a3a Re-add Freebsd Support 2019-02-08 19:17:30 -05:00
John Benediktsson 1b95fba178 Revert "io.files.temp: When using temp-file, it's possible that it fails since"
This reverts commit a274f99437.
2018-08-21 10:44:10 -07:00
Doug Coleman a274f99437 io.files.temp: When using temp-file, it's possible that it fails since
the temporary-directory does not exist yet.

Always check if the directory exists and create it if not.
2018-08-12 21:16:21 -05:00
Doug Coleman 4b614cc15b factor: Make source files/resources 644 instead of 755. 2018-07-13 20:36:50 -05:00
Doug Coleman 3ac520a8ec io.pathnames: Add canonicalize-path.
The idea is to make a canonical representation of any path, taking into
account . and .. and unicode-prefix on Windows.

The use case is in a shell you have a current-directory and you can do
crazy commands like ``cd ../foo/bar/baz/../.././././`` and get the
canonical/shortened directory name. You can also use this word to
compare if two paths are the same.
2018-07-07 11:59:59 -05:00
Doug Coleman 9f213f96f6 core: Add the shuffler words but without primitives.
The nipd branch slowed bootstrap by a minute, this patch does not.

sorry about changing the fjsc line endings...
2018-06-19 22:52:58 -05:00
John Benediktsson ca03896d74 more test IN: cleanup. 2018-02-15 09:20:01 -08:00
Alexander Iljin 504c9959a1 Update some copyright headers to follow the current convention
Had to look through the history to find years for some headers. Added
authors to some files as well.
2017-09-11 15:43:03 -07:00
Doug Coleman b92a3e109d io: Add with-ensure-directory and ?file-info. 2017-08-03 18:42:32 -05:00
Björn Lindqvist 9103d1546f basis/: more docs 2017-07-09 15:08:49 +02:00
Alexander Iljin 2ffa446f5b *-docs: replace double spaces with single spaces
Code examples and other places where multiple spaces were used to align
text were left intact.
2017-06-05 13:16:07 -07:00
Doug Coleman e189954ecc core: Rename iota to <iota> so we can have TUPLE: iota ... ; instead of TUPLE: iota-tuple ... ; 2017-06-02 11:57:05 -05:00
Doug Coleman 7c7bb93c55 factor: Rename GENERIC# to GENERIC#:.
Fixes #1670.
2017-06-01 13:58:58 -05:00
Doug Coleman df189eada5 io.files.info.windows: Fix using list.
We are using fry twice and it shows up in bootstrap.
2017-05-31 18:40:08 -05:00
John Benediktsson 3a6eefcc8e using ignore-errors instead of [ drop ] recover. 2017-02-09 15:50:33 -08:00
John Benediktsson 210209ead2 io.files.temp.macosx: use find instead of map-find. 2017-02-07 10:57:37 -08:00
John Benediktsson 48c69cb8ea use reject instead of [ ... not ] filter. 2017-01-05 13:29:58 -08:00
Björn Lindqvist a1c503c6e4 io.files.info.unix.linux: handles the possible permission denied error in M: linux file-systems 2016-11-19 02:07:49 +01:00
Björn Lindqvist 00d4572e6c basis,extra: refactorings to use the ignore-error and ignore-error/f words 2016-11-18 23:41:36 +01:00
John Benediktsson 3641defa66 io.files.temp.unix: make default-cache-directory absolute-path. 2016-11-10 09:08:29 -08:00
John Benediktsson edfcc879fe io.files.temp.unix: fix cache to be ~/.cache/factor. 2016-11-09 16:28:49 -08:00
John Benediktsson 3cc16ccd9e io.files.temp.unix: allowing TMPDIR to override /tmp. 2016-11-08 21:37:51 -08:00
John Benediktsson deac792fc7 io.files.temp.unix: changing cache directory to use XDG spec.
Typically this means ~/.cache/factor.
2016-11-08 21:24:34 -08:00
Alexander Iljin ebfce1deea io.files.info-docs: fix links to file-info-tuple parameters 2016-07-30 09:25:30 -07:00
Alexander Iljin b43c7b4fd7 io.files.info.windows: suppress ERROR_FILE_NOT_FOUND in volume>paths 2016-06-22 11:27:26 -07:00
Alexander Iljin d243e00f54 io.files.windows: use open-file to implement maybe-create-file
This fixes error throwing in case of CreateFile failure, and calls
add-completion for the file handle on success.
2016-06-22 11:27:26 -07:00