dl-fedora 1.2 → 1.2.1
raw patch · 4 files changed
+40/−14 lines, 4 filesdep ~simple-cmd
Dependency ranges changed: simple-cmd
Files
- CHANGELOG.md +3/−0
- README.md +9/−9
- dl-fedora.cabal +2/−2
- src/Main.hs +26/−3
CHANGELOG.md view
@@ -1,5 +1,8 @@ # Changelog +## 1.2.1 (2024-11-01)+- add MiracleWM and KDE_Mobile Live images+ ## 1.2 (2024-09-17) - default centos-stream to mirror.stream.centos.org - initial support for CS Alternative Live respins
README.md view
@@ -60,21 +60,21 @@ ``` Fedora iso downloader -Usage: dl-fedora [--version] [-g|--gpg-keys] [--no-checksum | --checksum]- [--debug] [-T|--no-http-timeout]- [(-c|--check) | (-l|--local) | --list | (-R|--replace)]- [-n|--dry-run] [-r|--run]- [(-L|--latest) | (-d|--dl) | (-k|--koji) | (-m|--mirror URL)]- [--dvd] [--cs-live-respin]+Usage: dl-fedora [--version] [-g|--gpg-keys] [--no-checksum | --checksum] + [--debug] [-T|--no-http-timeout] + [(-c|--check) | (-l|--local) | --list | (-R|--replace)] + [-n|--dry-run] [-r|--run] + [(-L|--latest) | (-d|--dl) | (-k|--koji) | (-m|--mirror URL)] + [--dvd] [--cs-live-respin] [--cs-devel | --cs-test | --cs-production] [-a|--arch ARCH] RELEASE [EDITION] Tool for downloading Fedora iso file images. RELEASE = release number, respin, rawhide, test (Beta), stage (RC), eln, c9s, c10s EDITION = {cloud,container,everything,server,workstation,budgie,cinnamon,i3,- kde,lxde,lxqt,mate,soas,sway,xfce,silverblue,kinoite,onyx,sericea,- iot} [default: workstation]-+ kde,kdemobile,lxde,lxqt,mate,miracle,soas,sway,xfce,silverblue,+ kinoite,onyx,sericea,iot} [default: workstation]+ See <https://github.com/juhp/dl-fedora/#readme> Available options:
dl-fedora.cabal view
@@ -1,6 +1,6 @@ cabal-version: 1.18 name: dl-fedora-version: 1.2+version: 1.2.1 synopsis: Fedora image download tool description: Tool to download Fedora and Centos Stream iso and image files.@@ -42,7 +42,7 @@ http-types, optparse-applicative, regex-posix,- simple-cmd >= 0.2.7,+ simple-cmd >= 0.2, simple-cmd-args >= 0.1.8, simple-prompt >= 0.2, text,
src/Main.hs view
@@ -31,7 +31,13 @@ import SimpleCmd (cmd, cmd_, cmdBool, cmdN, error', grep_, logMsg, pipe_, pipeBool, pipeFile_,- sudoLog, warning, (+-+))+ warning, (+-+),+#if MIN_VERSION_simple_cmd(0,2,7)+ sudoLog+#else+ sudo_+#endif+ ) import SimpleCmdArgs import SimplePrompt (yesNo, yesNoDefault) @@ -62,9 +68,11 @@ | Cinnamon | I3 | KDE+ | KDEMobile -- made with Kiwi | LXDE | LXQt | MATE+ | Miracle -- made with Kiwi | SoaS | Sway | Xfce -- last spin: used below@@ -76,7 +84,9 @@ deriving (Show, Enum, Bounded, Eq) showEdition :: FedoraEdition -> String+showEdition KDEMobile = "KDE-Mobile" showEdition MATE = "MATE_Compiz"+showEdition Miracle = "MiracleWM" showEdition I3 = "i3" showEdition e = show e @@ -100,6 +110,9 @@ fedoraSpins :: [FedoraEdition] fedoraSpins = [Budgie .. Xfce] +kiwiSpins :: [FedoraEdition]+kiwiSpins = [Miracle, KDEMobile]+ data CheckSum = AutoCheckSum | NoCheckSum | CheckSum deriving Eq @@ -328,7 +341,7 @@ user <- getLoginName sudoLog "chown" [user,localfile] else- error' $ localfile <> " does have write permission, aborting!"+ error' $ localfile <> " does not have write permission, aborting!" findMirror primeUrl path file else findMirror primeUrl path file let finalDir = dropFileName finalurl@@ -502,7 +515,10 @@ IoT -> ("", rel ++ [".*" <> showArch arch]) Cloud -> ('.' : showArch arch, rel) Container -> ('.' : showArch arch, rel)- _ -> ("", showArch arch : rel)+ _ -> ("",+ if edition `elem` kiwiSpins+ then rel+ else showArch arch : rel) in intercalate "-" (["Fedora", showEdition edition, editionType edition ++ midpref] ++ middle) @@ -750,3 +766,10 @@ csLive MATE = "MATE" csLive Xfce = "XFCE" csLive ed = error' $ "unsupported edition:" +-+ showEdition ed++#if !MIN_VERSION_simple_cmd(0,2,7)+sudoLog :: String -- ^ command+ -> [String] -- ^ arguments+ -> IO ()+sudoLog = sudo_+#endif