├── .github └── workflows │ └── main.yml ├── commands.md └── README.md /.github/workflows/main.yml: -------------------------------------------------------------------------------- 1 | on: 2 | push: 3 | branches: 4 | - main 5 | 6 | jobs: 7 | contrib-readme-job: 8 | runs-on: ubuntu-latest 9 | name: A job to automate contrib in readme 10 | steps: 11 | - name: Contribute List 12 | uses: akhilmhdh/contributors-readme-action@v2.3.6 13 | env: 14 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} -------------------------------------------------------------------------------- /commands.md: -------------------------------------------------------------------------------- 1 | # List of Commands 2 | 3 | ## Commands to control the computer 4 | 5 | Name | Command 6 | ----------------|-------------------------- 7 | shutdown | `systemctl poweroff` 8 | reboot | `systemctl restart` 9 | suspend | `systemctl suspend` 10 | hibernate | `systemctl hibernate` 11 | lock screen | `loginctl lock-session` 12 | unlock screen | `loginctl unlock-session` 13 | turn screen off | `xset dpms force off` 14 | turn screen on | `xset dpms force on` 15 | 16 | ## Volume control 17 | 18 | Name | Command 19 | ----------------|------------------------------------------------------------------------------ 20 | volume down | `qdbus org.kde.kglobalaccel /component/kmix invokeShortcut "decrease_volume"` 21 | volume up | `qdbus org.kde.kglobalaccel /component/kmix invokeShortcut "increase_volume"` 22 | mute | `qdbus org.kde.kglobalaccel /component/kmix invokeShortcut "mute"` 23 | mute microphone | `qdbus org.kde.kglobalaccel /component/kmix invokeShortcut "mic_mute"` 24 | 25 | ## With these commands you can control the brightness level 26 | 27 | Name | Command 28 | ----------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ 29 | brightness up | `qdbus org.kde.Solid.PowerManagement /org/kde/Solid/PowerManagement/Actions/BrightnessControl org.kde.Solid.PowerManagement.Actions.BrightnessControl.setBrightness $(expr $(qdbus org.kde.Solid.PowerManagement /org/kde/Solid/PowerManagement/Actions/BrightnessControl org.kde.Solid.PowerManagement.Actions.BrightnessControl.brightness) + 375)` 30 | brightness down | `qdbus org.kde.Solid.PowerManagement /org/kde/Solid/PowerManagement/Actions/BrightnessControl org.kde.Solid.PowerManagement.Actions.BrightnessControl.setBrightness $(expr $(qdbus org.kde.Solid.PowerManagement /org/kde/Solid/PowerManagement/Actions/BrightnessControl org.kde.Solid.PowerManagement.Actions.BrightnessControl.brightness) - 375)` 31 | 32 | ## Screenshots manipulation 33 | 34 | Name | Command 35 | --------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ 36 | screenshot | `spectacle -b` 37 | screenshot to phone | `file=/tmp/$(hostname)_$(date "+%d%m%Y_%H%M%S").png; spectacle -bno "${file}" && kdeconnect-cli -d $(kdeconnect-cli -a --id-only) --share ${file}` 38 | webcam to phone | `file="$HOME/Pictures/WebcamImage_$(date "+%d%m%Y_%H%M%S").jpg"; ffmpeg -f video4linux2 -input_format mjpeg -s 1280x720 -i /dev/video0 -frames:v 1 "${file}" && kdeconnect-cli -d $(kdeconnect-cli -a --id-only) --share "${file}"` 39 | 40 | ## Virtual Desktop manipulation 41 | 42 | Name | Command 43 | ------------|----------------------------------------------- 44 | VD main | `qdbus org.kde.KWin /KWin setCurrentDesktop 1` 45 | VD next | `qdbus org.kde.KWin /KWin nextDesktop` 46 | VD previous | `qdbus org.kde.KWin /KWin previousDesktop` 47 | 48 | ## Change look and feel 49 | 50 | Name | Command 51 | -----------------|-------------------------------------------------- 52 | Set Breeze light | `lookandfeeltool -a 'org.kde.breeze.desktop'` 53 | Set Breeze dark | `lookandfeeltool -a 'org.kde.breezedark.desktop'` 54 | 55 | ## Send output of any command to your phone 56 | 57 | Name | Command 58 | ----------------------|------------------------------------------------------------------------------------------------------------------------- 59 | speedtest-cli summary | `kdeconnect-cli -d $(kdeconnect-cli -a --id-only) --ping-msg "$(speedtest-cli \| awk 'NR==5;NR==7;NR==9 {print;exit}')"` 60 | uptime | `kdeconnect-cli -d $(kdeconnect-cli -a --id-only) --ping-msg "$(uptime \| cut -d" " -f2-)"` 61 | list logged users | `kdeconnect-cli -d $(kdeconnect-cli -a --id-only) --ping-msg "$(who)"` 62 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # KDEConnect-commands 2 | 3 | [Click here](https://github.com/guinuxbr/KDEConnect-commands/blob/master/commands.md) to see the commands. 4 | 5 | ![GitHub repo size](https://img.shields.io/github/repo-size/guinuxbr/KDEConnect-commands) 6 | ![GitHub contributors](https://img.shields.io/github/contributors/guinuxbr/KDEConnect-commands) 7 | ![GitHub stars](https://img.shields.io/github/stars/guinuxbr/KDEConnect-commands) 8 | ![GitHub forks](https://img.shields.io/github/forks/guinuxbr/KDEConnect-commands) 9 | ![Twitter Follow](https://img.shields.io/twitter/follow/guinuxbr?style=social) 10 | 11 | Here is my `KDEConnect-commands` that allows to control your Plasma Desktop from your Android phone. It uses [KDEConnect](https://community.kde.org/KDEConnect) that is capable to do some really cool stuff. In fact, you can do almost anything like send files from and to phone, control slideshow presentation, control multimedia application, remote input and the ability to run commands directly in your Linux box. 12 | 13 | This repository contains a list of commands to be used in KDE Connect. 14 | 15 | ## Prerequisites 16 | 17 | Before you begin, ensure you have met the following requirements: 18 | To use it, you have to install KDE Connect package on your Linux distribution and the app in your Android phone. 19 | 20 | The Android app can be found at [Google Play Store](https://play.google.com/store/apps/details?id=org.kde.kdeconnect_tp) and [F-Droid](https://f-droid.org/packages/org.kde.kdeconnect_tp/). 21 | 22 | You should have kde-connect package installed on your Linux system. In this example, I use Arch Linux. 23 | 24 | ```bash 25 | sudo pacman -S kdeconnect 26 | ``` 27 | 28 | The package have some optional dependencies (in Arch Linux) that you should install to be able to use the respective feature in KDE Connect. 29 | 30 | - **sshfs**: remote filesystem browser 31 | - **kde-cli-tools**: configuration UI 32 | - **qt5-declarative**: QML bindings 33 | - **python-nautilus**: Nautilus integration 34 | 35 | ## Using KDEConnect-commands 36 | 37 | To use KDEConnect-commands, follow these steps: 38 | 39 | - Access KDE `System Settings` > `KDE Connect`. 40 | - Choose your device on the list and then `Run commands` 41 | 42 | In the window that shows up you should give a smart name and copy the command line at the column "Command". 43 | Press "OK" and you are done. 44 | 45 | More information about KDEConnect project can be found at [KDE Community Wiki](https://community.kde.org/KDEConnect). 46 | 47 | ## Contributing to KDEConnect-commands 48 | 49 | To contribute to KDEConnect-commands, follow these steps: 50 | 51 | 1. Fork this repository. 52 | 2. Create a branch: `git checkout -b ` 53 | 3. Make your changes and commit them: `git commit -m ''` 54 | 4. Push to the original branch: `git push origin KDEConnect-commands/` 55 | 5. Create the pull request 56 | 57 | Alternatively see the GitHub documentation on [creating a pull request](https://help.github.com/en/github/collaborating-with-issues-and-pull-requests/creating-a-pull-request). 58 | 59 | ## Maintainer 60 | 61 | I'm the only one here! Help me! 🙂 62 | 63 | - [@guinuxbr](https://github.com/guinuxbr) 64 | 65 | ## Contributors 66 | 67 | But there are cool contributors: 68 | 69 | 70 | 71 | 72 | 79 | 86 | 93 |
73 | 74 | 5ucur 75 |
76 | Null 77 |
78 |
80 | 81 | harshallcode 82 |
83 | Harshal Patil 84 |
85 |
87 | 88 | LeCleric 89 |
90 | William Leclerc 91 |
92 |
94 | 95 | 96 | ## Contact 97 | 98 | If you want to contact me you can send an email to . 99 | 100 | ## License 101 | 102 | This project uses the following license: [GNU GPLv3](https://www.gnu.org/licenses/gpl-3.0.html). 103 | --------------------------------------------------------------------------------