summaryrefslogtreecommitdiff
path: root/fsmgr.hs
diff options
context:
space:
mode:
authorAndrew Cady <d@jerkface.net>2020-06-19 08:00:42 -0400
committerAndrew Cady <d@jerkface.net>2020-06-19 08:00:42 -0400
commitf49e4f88d55b0340ea69091a2f1a91882f199940 (patch)
treedb75a1cec692941427ad1b1c13e0b1990c5a2eea /fsmgr.hs
parent53ae74b98a12cb137c5299d1e3a9a715db09c9a0 (diff)
insert TODO
Diffstat (limited to 'fsmgr.hs')
-rw-r--r--fsmgr.hs48
1 files changed, 47 insertions, 1 deletions
diff --git a/fsmgr.hs b/fsmgr.hs
index 2ea67d3..3eee8bd 100644
--- a/fsmgr.hs
+++ b/fsmgr.hs
@@ -65,8 +65,54 @@ data AptListCfg =
65 , translationLang :: String 65 , translationLang :: String
66 } 66 }
67 67
68{-
69TODO: language should derive from $LC_MESSAGES as implemented by apt:
70
71 Manual page apt.conf(5)
72
73 Languages
74
75 The Languages subsection controls which Translation files
76 are downloaded and in which order APT tries to display
77 the description-translations. APT will try to display
78 the first available description in the language which is
79 listed first. Languages can be defined with their short or
80 long language codes. Note that not all archives provide
81 Translation files for every language - the long language
82 codes are especially rare.
83
84 The default list includes "environment" and "en".
85 "environment" has a special meaning here: it will be
86 replaced at runtime with the language codes extracted from
87 the LC_MESSAGES environment variable. It will also ensure
88 that these codes are not included twice in the list. If
89 LC_MESSAGES is set to "C" only the Translation-en file (if
90 available) will be used. To force APT to use no Translation
91 file use the setting Acquire::Languages=none. "none" is
92 another special meaning code which will stop the search for
93 a suitable Translation file. This tells APT to download
94 these translations too, without actually using them unless
95 the environment specifies the languages. So the following
96 example configuration will result in the order "en, de" in an
97 English locale or "de, en" in a German one. Note that "fr"
98 is downloaded, but not used unless APT is used in a French
99 locale (where the order would be "fr, de, en").
100
101 Acquire::Languages { "environment"; "de"; "en"; "none";
102 "fr"; };
103
104 Note: To prevent problems resulting from APT being executed
105 in different environments (e.g. by different users or by
106 other programs) all Translation files which are found in
107 /var/lib/apt/lists/ will be added to the end of the list
108 (after an implicit "none").
109
110-}
111language :: String
112language = "en"
113
68aptListCfg :: AptListCfg 114aptListCfg :: AptListCfg
69aptListCfg = AptListCfg getDebianCodename debarch "en" 115aptListCfg = AptListCfg getDebianCodename debarch language
70 116
71aptListFiles :: AptListCfg -> [FilePath] 117aptListFiles :: AptListCfg -> [FilePath]
72aptListFiles AptListCfg{..} = 118aptListFiles AptListCfg{..} =