Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mkimage-profiles
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ximper Linux
mkimage-profiles
Commits
424373cb
Commit
424373cb
authored
Jan 30, 2025
by
Anton Midyukov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cleanup: refactoring live/image-scripts.d/80-locales
parent
49a33ad8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
15 deletions
+16
-15
80-locales
features.in/cleanup/live/image-scripts.d/80-locales
+13
-12
50-l10n-sysconfig
features.in/l10n/rootfs/image-scripts.d/50-l10n-sysconfig
+3
-3
No files found.
features.in/cleanup/live/image-scripts.d/80-locales
View file @
424373cb
#!/bin/sh
# FIXME: there should be less brutal i18n tuning
# don't cripple the image to be copied over
[
-n
"
$GLOBAL_LIVE_INSTALL
"
]
||
\
[
-x
/usr/sbin/live-install
]
||
\
[
-x
/usr/sbin/livecd-install
]
&&
exit
0
[
-z
"
$GLOBAL_LIVE_INSTALL
"
]
||
exit
0
[
!
-x
/usr/sbin/live-install
]
||
exit
0
[
!
-x
/usr/sbin/livecd-install
]
||
exit
0
if
[
-n
"
$GLOBAL_LOCALES
"
]
;
then
# -not -name C* -a -not -name en* -a -not -name ru*
LOCALES
=
"
$(
echo
"C*"
$GLOBAL_LOCALES
|
sed
's/ / -a -not -name /g;s/^/-not -name /;s/_[A-Z]*/*/g'
)
"
else
LOCALES
=
"-not -name C*"
fi
find /usr/share/locale /usr/lib/locale
-mindepth
1
-maxdepth
1
\
$LOCALES
-exec
rm
-r
{}
\;
cd
/usr/share/locale
rm
-r
*
@
*
for
i
in
*
/
;
do
case
"
$i
"
in
be
*
|
en
*
|
ru
*
|
uk
*
)
continue
;;
esac
rm
-r
"
$i
"
done
:
features.in/l10n/rootfs/image-scripts.d/50-l10n-sysconfig
View file @
424373cb
...
...
@@ -18,8 +18,8 @@ if [ -f "$langlist" ] && [ -n "$locales" ]; then
fi
if
[
-n
"
$locale
"
]
;
then
which localectl 2>&1
>
/dev/null
&&
echo
LANG
=
"
$locale
"
.UTF8
>
"
$systemd_locale
"
[
-f
"
$sysv_locale
"
]
&&
echo
LANG
=
"
$locale
"
.UTF8
>
"
$sysv_locale
"
[
-f
"
$sysv_locale
"
]
&&
echo
SUPPORTED
=
"
$locale
"
.UTF8
>>
"
$sysv_locale
"
which localectl 2>&1
>
/dev/null
&&
echo
LANG
=
"
$locale
"
.UTF
-
8
>
"
$systemd_locale
"
[
-f
"
$sysv_locale
"
]
&&
echo
LANG
=
"
$locale
"
.UTF
-
8
>
"
$sysv_locale
"
[
-f
"
$sysv_locale
"
]
&&
echo
SUPPORTED
=
"
$locale
"
.UTF
-
8
>>
"
$sysv_locale
"
fi
:
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment