Differences From Artifact [448648acfa]:
- File
utils/ofarc/OFArc.m
— part of check-in
[88ed5be671]
at
2022-11-23 21:39:13
on branch trunk
— Use a URI for the localization directory
This theoretically allows embedding localizations. While this isn't
great as all will be held in memory but only one will be used, there
might be cases where everything should be in one binary. (user: js, size: 21780) [annotate] [blame] [check-ins using]
To Artifact [08dae94193]:
- File utils/ofarc/OFArc.m — part of check-in [23272e6d43] at 2022-11-24 00:21:15 on branch trunk — Rename OFURI to OFIRI (user: js, size: 21780) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 | #include <string.h> #import "OFApplication.h" #import "OFArray.h" #import "OFFile.h" #import "OFFileManager.h" #import "OFLocale.h" #import "OFOptionsParser.h" #import "OFSandbox.h" #import "OFStdIOStream.h" | > < | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 | #include <string.h> #import "OFApplication.h" #import "OFArray.h" #import "OFFile.h" #import "OFFileManager.h" #import "OFIRI.h" #import "OFLocale.h" #import "OFOptionsParser.h" #import "OFSandbox.h" #import "OFStdIOStream.h" #import "OFArc.h" #import "GZIPArchive.h" #import "LHAArchive.h" #import "TarArchive.h" #import "ZIPArchive.h" |
︙ | ︙ | |||
203 204 205 206 207 208 209 | /* Dropped after parsing options */ sandbox.allowsUnveil = true; [OFApplication of_activateSandbox: sandbox]; #endif #ifndef OF_AMIGAOS | | | | | | 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 | /* Dropped after parsing options */ sandbox.allowsUnveil = true; [OFApplication of_activateSandbox: sandbox]; #endif #ifndef OF_AMIGAOS [OFLocale addLocalizationDirectoryIRI: [OFIRI fileIRIWithPath: @LOCALIZATION_DIR]]; #else [OFLocale addLocalizationDirectoryIRI: [OFIRI fileIRIWithPath: @"PROGDIR:/share/ofarc/localization"]]; #endif optionsParser = [OFOptionsParser parserWithOptions: options]; while ((option = [optionsParser nextOption]) != '\0') { switch (option) { case 'f': if (_overwrite < 0) |
︙ | ︙ | |||
459 460 461 462 463 464 465 | OFString *error = [OFString stringWithCString: strerror(e.errNo) encoding: [OFLocale encoding]]; [OFStdErr writeString: @"\r"]; [OFStdErr writeLine: OF_LOCALIZED( @"failed_to_create_directory", @"Failed to create directory %[dir]: %[error]", | | | 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 | OFString *error = [OFString stringWithCString: strerror(e.errNo) encoding: [OFLocale encoding]]; [OFStdErr writeString: @"\r"]; [OFStdErr writeLine: OF_LOCALIZED( @"failed_to_create_directory", @"Failed to create directory %[dir]: %[error]", @"dir", e.IRI.fileSystemRepresentation, @"error", error)]; _exitStatus = 1; } @catch (OFOpenItemFailedException *e) { OFString *error = [OFString stringWithCString: strerror(e.errNo) encoding: [OFLocale encoding]]; [OFStdErr writeString: @"\r"]; |
︙ | ︙ |