Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall/lib/locale_helpers.py
AgeCommit message (Collapse)Author
2023-05-11Cleanup imports and unused code (#1801)Daniel Girtler
* Cleanup imports and unused code * Update build check * Keep deprecation exception * Simplify logging --------- Co-authored-by: Daniel Girtler <girtler.daniel@gmail.com>
2023-05-04Update `SysCommand()` calls in remaining files (#1707)Daemon Coder
2023-04-19PyParted and a large rewrite of the underlying partitioning (#1604)Daniel Girtler
* Invert mypy files * Add optional pre-commit hooks * New profile structure * Serialize profiles * Use profile instead of classmethod * Custom profile setup * Separator between back * Support profile import via url * Move profiles module * Refactor files * Remove symlink * Add user to docker group * Update schema description * Handle list services * mypy fixes * mypy fixes * Rename profilesv2 to profiles * flake8 * mypy again * Support selecting DM * Fix mypy * Cleanup * Update greeter setting * Update schema * Revert toml changes * Poc external dependencies * Dependency support * New encryption menu * flake8 * Mypy and flake8 * Unify lsblk command * Update bootloader configuration * Git hooks * Fix import * Pyparted * Remove custom font setting * flake8 * Remove default preview * Manual partitioning menu * Update structure * Disk configuration * Update filesystem * luks2 encryption * Everything works until installation * Btrfsutil * Btrfs handling * Update btrfs * Save encryption config * Fix pipewire issue * Update mypy version * Update all pre-commit * Update package versions * Revert audio/pipewire * Merge master PRs * Add master changes * Merge master changes * Small renaming * Pull master changes * Reset disk enc after disk config change * Generate locals * Update naming * Fix imports * Fix broken sync * Fix pre selection on table menu * Profile menu * Update profile * Fix post_install * Added python-pyparted to PKGBUILD, this requires [testing] to be enabled in order to run makepkg. Package still works via python -m build etc. * Swaped around some setuptools logic in pyproject Since we define `package-data` and `packages` there should be no need for: ``` [tool.setuptools.packages.find] where = ["archinstall", "archinstall.*"] ``` * Removed pyproject collisions. Duplicate definitions. * Made sure pyproject.toml includes languages * Add example and update README * Fix pyproject issues * Generate locale * Refactor imports * Simplify imports * Add profile description and package examples * Align code * Fix mypy * Simplify imports * Fix saving config * Fix wrong luks merge * Refactor installation * Fix cdrom device loading * Fix wrongly merged code * Fix imports and greeter * Don't terminate on partprobe error * Use specific path on partprobe from luks * Update archinstall/lib/disk/device_model.py Co-authored-by: codefiles <11915375+codefiles@users.noreply.github.com> * Update archinstall/lib/disk/device_model.py Co-authored-by: codefiles <11915375+codefiles@users.noreply.github.com> * Update github workflow to test archinstall installation * Update sway merge * Generate locales * Update workflow --------- Co-authored-by: Daniel Girtler <girtler.daniel@gmail.com> Co-authored-by: Anton Hvornum <anton@hvornum.se> Co-authored-by: Anton Hvornum <anton.feeds+github@gmail.com> Co-authored-by: codefiles <11915375+codefiles@users.noreply.github.com>
2022-08-01Remove the hash/number sign at the line-start (#1345)Fabian Bornschein
Currently the helper remove the first character of each line, this can lead to cases, where important characters are removed. For example if the locale is already set up. (hash is already removed) in that case the helper would remove the first character of the locale and lead to a broken attempt to set the locale later on. This change should avoid that and only remove the hash. Co-authored-by: Fabian Bornschein <2440175-fabiscafe@users.noreply.gitlab.com>
2022-02-03Command locales (second batch) (#886)Werner Llácer
* flexibilize the definition of execution locale for OS commands executed via the SysCommand* interface. Defined a storage argument which holds the default Added functions to unset the program own locales reset to the program default locales set a specific locale A decorator to execute functions in the host locale environment * rename decorator local_environ to host_locale_environ created a simmetric decorator c_locale_environ, to make a routine work with the C locale whatever is set * Correct definition of btrfs standard layout * Added error handling * Fixed issue where archinstall.Boot() would raise an exception in vain * Added debugging for SysCommandWorker() * Added some debugging * Tweaking debug a bit * Tweaking debug * Adding more debug * Adding more debug * Removed some debugging * Adding more debug * Adding more debug * Adding more debug * Adding more debug * Adding more debug * Adding more debug * Adding more debug * Adding more debug * Adding more debug * Adding more debug * Adding more debug * Removed soem debugging * Removed soem debugging * Testing a revert * Adding back the reverted change, adding lofile * Redirecting stdout to /dev/null for testing (to avoid interrupting the fork) * Reverted debug changes * Testing os.system() Co-authored-by: Anton Hvornum <anton@hvornum.se>
2022-01-07Global menu (#806)Daniel
* Global menu * Fix flake8 * Refactor code * Add documentation * Fix flake8 * Add support for user flow mentioned in #799 * Move import * Fix flake8 (again) Co-authored-by: Daniel Girtler <girtler.daniel@gmail.com> Co-authored-by: Anton Hvornum <anton.feeds@gmail.com>
2022-01-06Added type annotations to all functions (#845)Anton Hvornum
* Added type annotations for 1/5 of the files. There's bound to be some issues with type miss-match, will sort that out later. * Added type hints for 4/5 of the code * Added type hints for 4.7/5 of the code * Added type hints for 5/5 of the code base * Split the linters into individual files This should help with more clearly show which runner is breaking since they don't share a single common name any longer. Also moved mypy settings into pyproject.toml * Fixed some of the last flake8 issues * Missing parameter * Fixed invalid lookahead types * __future__ had to be at the top * Fixed last flake8 issues
2021-12-02Add simple menu for better UX (#660)Daniel
* Add simple menu for better UX * Add remove external dependency * Fix harddisk return value on skip * Table output for partitioning process * Switch partitioning to simple menu * fixup! Switch partitioning to simple menu * Ignoring complexity and binary operator issues Only in simple_menu.py * Added license text to the MIT licensed file * Added in versioning information * Fixed some imports and removed the last generic_select() from user_interaction. Also fixed a revert/merged fork of ask_for_main_filesystem_format() * Update color scheme to match Arch style better * Use cyan as default cursor color * Leave simple menu the same Co-authored-by: Daniel Girtler <girtler.daniel@gmail.com> Co-authored-by: Anton Hvornum <anton.feeds+github@gmail.com> Co-authored-by: Dylan M. Taylor <dylan@dylanmtaylor.com>
2021-05-19Reworking SysCommand & Moving to localectl for locale related activitiesAnton Hvornum
* Moving to `localectl` rather than local file manipulation *(both for listing locales and setting them)*. * Swapped `loadkeys` for localectl. * Renamed `main` to `maim` in awesome profile. * Created `archinstall.Boot(<installation>)` which spawns a `systemd-nspawn` container against the installation target. * Exposing systemd.py's internals to archinstall global scope. * Re-worked `SysCommand` completely, it's now a wrapper for `SysCommandWorker` which supports interacting with the process in a different way. `SysCommand` should behave just like the old one, for backwards compatibility reasons. This fixes #68 and #69. * `SysCommand()` now has a `.decode()` function that defaults to `UTF-8`. * Adding back peak_output=True to pacstrap. Co-authored-by: Anton Hvornum <anton.feeds@gmail.com> Co-authored-by: Dylan Taylor <dylan@dylanmtaylor.com>
2021-05-15Fix some variable shadowing issuesDylan Taylor
2021-05-15Some additional formattingDylan Taylor
2021-05-15Many more manual changesDylan Taylor
2021-04-22Fix other issues of language selectionSecondThundeR
2021-04-14Removed layout filteringAnton Hvornum
This caused languages such as `be-latin1` to be hidden both in Search and direct input. Because as an example that layout belongs to `azerty` and not `qwerty`.
2021-04-12Replace os.system with subprocess.callJakobDev
2020-09-07Spelling error in locale helpers.Anton Hvornum
2020-09-01Added locale helpers in terms of keyboard language/layout. ↵Anton Hvornum
archinstall.list_keyboard_languages(), archinstall.search_keyboard_layout() and archinstall.set_keyboard_language() work together to help listing, finding and setting a keyboard layout in terminals. Won't work for X-frontends, but will do for CLI installation methods. Added a language selector-helper-function with a crude search functionality. Added all this to the guided template.