Manjaro Difference between revisions of "CheatSheet/ru"

Difference between revisions of "CheatSheet/ru"

From Manjaro
(Created page with "[https://forum.manjaro.org/t/manjaro-cli-cheat-sheet/101305 Оригинальное сообщение на форуме]")
Tags: Mobile web edit Mobile edit
(Created page with "Сгенерировать случайный список зеркал для пользователей и сортирует их по текущему времени до...")
Line 16: Line 16:
=== Обслуживание ===
=== Обслуживание ===


<div lang="en" dir="ltr" class="mw-content-ltr">
Сгенерировать случайный список зеркал для пользователей и сортирует их по текущему времени доступа. {{UserCmd|command=sudo pacman-mirrors --fasttrack}}
Generates  a  random  mirrorlist for the users and sort them by their current access time. {{UserCmd|command=sudo pacman-mirrors --fasttrack}}
Создать список кэша {{UserCmd|command=du -sh ~/.cache/*}}
Generate cache list {{UserCmd|command=du -sh ~/.cache/*}}
Очистить файлы, к которым не обращались в течение 100 дней {{UserCmd|command=find ~/.cache/ -type f -atime +100 -delete}}
Purge files not accessed in 100 days {{UserCmd|command=find ~/.cache/ -type f -atime +100 -delete}}
Сообщить текущий размер журнала {{UserCmd|command=journalctl --disk-usage}}
Report journal current size {{UserCmd|command=journalctl --disk-usage}}
Удалить последние записи по размеру или времени {{UserCmd|command=journalctl --vacuum-size=50M}} {{UserCmd|command=journalctl --vacuum-time=2weeks}}
Remove but recent entries by size or time {{UserCmd|command=journalctl --vacuum-size=50M}} {{UserCmd|command=journalctl --vacuum-time=2weeks}}
Проверить наличие осиротевших пакетов {{UserCmd|command=pamac list -o }}
Check for orphaned packages {{UserCmd|command=pamac list -o }}
Удалить все сиротские пакеты {{UserCmd|command=pamac remove -o }}
Remove all orphans {{UserCmd|command=pamac remove -o }}
Удалить все пакеты, кроме последних 3 версий {{UserCmd|command=pamac clean --keep 3}}
Remove all packages except the latest 3 versions {{UserCmd|command=pamac clean --keep 3}}
</div>


=== AUR ===
=== AUR ===

Revision as of 11:58, 17 December 2022

Other languages:
Deutsch • ‎English • ‎Türkçe • ‎русский

Шпаргалка по командам Manjaro

Поиск и установка пакетов

Установка пакетов

user $ pamac install [PackageName] COPY TO CLIPBOARD


Удаление пакетов

user $ pamac remove [PackageName] COPY TO CLIPBOARD


Поиск пакета

user $ pamac search [PackageName] COPY TO CLIPBOARD


Обновление установленных пакетов

user $ pamac upgrade COPY TO CLIPBOARD


Проверка обновлений

user $ pamac checkupdates COPY TO CLIPBOARD


Обслуживание

Сгенерировать случайный список зеркал для пользователей и сортирует их по текущему времени доступа.

user $ sudo pacman-mirrors --fasttrack COPY TO CLIPBOARD


Создать список кэша

user $ du -sh ~/.cache/* COPY TO CLIPBOARD


Очистить файлы, к которым не обращались в течение 100 дней

user $ find ~/.cache/ -type f -atime +100 -delete COPY TO CLIPBOARD


Сообщить текущий размер журнала

user $ journalctl --disk-usage COPY TO CLIPBOARD


Удалить последние записи по размеру или времени

user $ journalctl --vacuum-size=50M COPY TO CLIPBOARD


user $ journalctl --vacuum-time=2weeks COPY TO CLIPBOARD


Проверить наличие осиротевших пакетов

user $ pamac list -o COPY TO CLIPBOARD


Удалить все сиротские пакеты

user $ pamac remove -o COPY TO CLIPBOARD


Удалить все пакеты, кроме последних 3 версий

user $ pamac clean --keep 3 COPY TO CLIPBOARD


AUR

Поиск пакета

user $ pamac search -a [PackageName] COPY TO CLIPBOARD


Сборка пакета

user $ pamac build [PackageName] COPY TO CLIPBOARD


Права доступа

Execute command as root
user $ sudo [command] COPY TO CLIPBOARD

Empty password cache

user $ sudo -k COPY TO CLIPBOARD


Change user password

user $ passwd username COPY TO CLIPBOARD


Change owner and group of file

user $ chown [owner]:[group] -c [file] COPY TO CLIPBOARD


Change file permissions

user $ chmod [permissions] -c [file] COPY TO CLIPBOARD


Set permissions in octal mode: 4(read) 2(write) 1(execute)

Example: 755 read-write-execute for owner and read-execute for group and others

Display files and permissions [of directory]
user $ ls -lh [dir] COPY TO CLIPBOARD

Файлы и каталоги

Change the working directory
user $ cd [dir] COPY TO CLIPBOARD

Change to parent directory

user $ cd .. COPY TO CLIPBOARD


List directory contents

user $ ls -l COPY TO CLIPBOARD


List also hidden files

user $ ls -la COPY TO CLIPBOARD


Copy file

user $ cp [file] [target] COPY TO CLIPBOARD


Copy directory recursively

user $ cp -r [directory] [target] COPY TO CLIPBOARD


Move or rename file/directory

user $ mv [source] [target] COPY TO CLIPBOARD


Remove directory recursively

user $ rm -r [dir] COPY TO CLIPBOARD


Create symbolic link

user $ ln -s [target] [link] COPY TO CLIPBOARD


Mount filesystem

user $ mount -t [type] [/dev/sdx9] [mountpoint] COPY TO CLIPBOARD


Mount ISO image

user $ mount -o loop [iso] [mountpoint] COPY TO CLIPBOARD


Home directory of user

user $ cd /home/$USER COPY TO CLIPBOARD


user $ cd ~ COPY TO CLIPBOARD


Directory with global configurations

user $ cd /etc COPY TO CLIPBOARD


Сеть

Display network information
user $ nmcli COPY TO CLIPBOARD

List wireless access points

user $ nmcli c COPY TO CLIPBOARD


Enable firewall [package Community: ufw]

user $ ufw enable COPY TO CLIPBOARD


Allow/deny all incoming traffic

user $ ufw default [allow/deny] COPY TO CLIPBOARD


Displays firewall status and rules

user $ ufw status COPY TO CLIPBOARD


Allows/deny incoming traffic on the specified port

user $ ufw [allow/deny] [port] COPY TO CLIPBOARD


Allows/deny incoming traffic from specified IP address

user $ ufw [allow/deny] from [ip] COPY TO CLIPBOARD


Система и экран

Display kernel version
user $ uname -r COPY TO CLIPBOARD

Display long kernel version

user $ uname -a COPY TO CLIPBOARD


Report file system disk space usage

user $ df [/] [/home] COPY TO CLIPBOARD


user $ sudo btrfs filesystem usage -h [/] COPY TO CLIPBOARD


Display system tasks

user $ top COPY TO CLIPBOARD


user $ htop COPY TO CLIPBOARD


Display system information

user $ inxi --admin --verbosity=7 --filter --width COPY TO CLIPBOARD


Display a tree of processes

user $ pstree COPY TO CLIPBOARD


Switch to tty

  • Ctrl+Alt+F1
  • Ctrl+Alt+F2
  • Ctrl+Alt+F3
  • Ctrl+Alt+F4
  • Ctrl+Alt+F5
  • Ctrl+Alt+F6

Switch to the X session

  • Ctrl+Alt+F7
Start a unit
user $ systemctl start unit COPY TO CLIPBOARD

Stop a unit

user $ systemctl stop unit COPY TO CLIPBOARD


Check status of a unit

user $ systemctl status unit COPY TO CLIPBOARD


Enable a unit

user $ systemctl enable unit COPY TO CLIPBOARD


Disable a unit

user $ systemctl disable unit COPY TO CLIPBOARD


Restart a unit

user $ systemctl restart unit COPY TO CLIPBOARD


Shut down the system

user $ poweroff COPY TO CLIPBOARD


Restart the system

user $ reboot COPY TO CLIPBOARD


Смотрете также

Оригинальное сообщение на форуме

Cookies help us deliver our services. By using our services, you agree to our use of cookies.