UBports Robot Logo

    UBports Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Solved Waydroid ... how to shut it down ?

    Waydroid
    9
    27
    5878
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • C
      cr9c last edited by

      Hi,
      I installed Waydroid on my FP3+ and everything is going on well ๐Ÿ‘
      Android apps which are installed there, leaves an icon in Ubuntu Touch Apps list so you can easily launch an Android App without first launch Waydroid.

      But to shut down Waydroid propperly I only found through terminal as it's explained here on waydro.id

      waydroid session stop
      sudo waydroid container stop
      

      ... so do you know if there's another option without using terminal to stop Waydroid ?

      For instance when I "slide away" waydroid as it's done for Ubuntu touch apps, Waydroid window disapears but you can't launch it again since it's running in the processuses ...

      c4pp4 1 Reply Last reply Reply Quote 0
      • c4pp4
        c4pp4 @cr9c last edited by c4pp4

        @cr9c Only 'waydroid session stop' is necessary. You need to keep the container started to launch waydroid again via menu icon.

        You can create a desktop launcher to stop waydroid session.
        e.g.:
        /home/phablet/.local/share/applications/waydroid-stop.desktop

        [Desktop Entry]
        Type=Application
        Name=Waydroid Stop
        Exec=waydroid session stop
        Icon=/usr/lib/waydroid/data/AppIcon.png
        

        You can create a script to additionally remove some android icons.
        e.g.
        /home/phablet/waydroid-stop.sh

        #!/bin/bash
        
        waydroid session stop
        rm .local/share/applications/com.android*
        rm .local/share/applications/org.lineageos*
        

        and make it executable:

        chmod +x /home/phablet/waydroid-stop.sh
        

        In that case the launcher should look like this:

        [Desktop Entry]
        Type=Application
        Name=Waydroid Stop
        Exec=/home/phablet/waydroid-stop.sh
        Icon=/usr/lib/waydroid/data/AppIcon.png
        
        C 1 Reply Last reply Reply Quote 0
        • C
          cr9c @c4pp4 last edited by

          Hi @c4pp4

          @cr9c Only 'waydroid session stop' is necessary. You need to keep the container started to launch waydroid again via menu icon.

          OK

          You can create a desktop launcher to stop waydroid session.
          e.g.:
          /home/phablet/.local/share/applications/waydroid-stop.desktop

          [Desktop Entry]
          Type=Application
          Name=Waydroid Stop
          Exec=waydroid session stop
          Icon=/usr/lib/waydroid/data/AppIcon.png
          

          Thank's for that, good idea I didn't think about ;o)

          You can create a script to additionally remove some android icons.
          ...

          However I don't understand this about removing Android Icons ?! Is there's any link with the way to stop Waydroid ?
          In what way is it useful ? Could you tel me why you wrote this ?

          Thank's anyway.

          c4pp4 H 2 Replies Last reply Reply Quote 0
          • c4pp4
            c4pp4 @cr9c last edited by

            @cr9c said in Waydroid ... how to shut it down ?:

            However I don't understand this about removing Android Icons

            If you don't want to have android icons in UT menu when waydroid is not running.

            C 1 Reply Last reply Reply Quote 0
            • C
              cr9c @c4pp4 last edited by

              @c4pp4 Thanks indeed.

              L 1 Reply Last reply Reply Quote 0
              • L
                Luksus @cr9c last edited by

                BTW. waydroid desktop files are perfixed with "waydroid" in current versions, like this:
                waydroid.org.fdroid.fdroid.desktop

                So (re)moving .local/share/applications/waydroid.*should be enough.

                (Would be nice, if there were some filter in the app drawer, then we could just filter by the desktop file prefix ;-))

                Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605, Pinephone, Moto Z2 Force

                C 1 Reply Last reply Reply Quote 0
                • C
                  cr9c @Luksus last edited by

                  Hi @luksus ,

                  And If I want to keep only one or two icons from this family "waydroid.*"
                  how should I proceed in the following script ... (In fact I'd like to make an exception ;o))

                  #!/bin/bash
                  
                  waydroid session stop
                  rm .local/share/applications/waydroid.*
                  
                  L 1 Reply Last reply Reply Quote 0
                  • L
                    Luksus @cr9c last edited by Luksus

                    @cr9c I don't know. ๐Ÿ˜‰

                    And I have the impression, that the desktop files, gets readded, when restarting waydroid, or when re-inititalizing... I am not sure. But it is not very comfortable to always move them away again...

                    Devices: BQ e4.5, Fairphone 2, Fairphone 3, Lenovo X605, Pinephone, Moto Z2 Force

                    ? 1 Reply Last reply Reply Quote 0
                    • H
                      Homer @cr9c last edited by

                      @cr9c hi, you have to mount the fike system writable to do this, right?

                      1 Reply Last reply Reply Quote 0
                      • ?
                        A Former User @Luksus last edited by A Former User

                        @luksus You can make icons hidden and the are not comming back add last not on my device to do this you can do following:

                        Hide launchers
                        If you want to keep the .desktop files but hide the launchers, add โ€œNoDisplay=trueโ€ to those you dont want to see. The following hides all Waydroid launchers:

                        for i in ~/.local/share/applications/waydroid*desktop; do echo 'NoDisplay=true' >> $i; done

                        Remove launchers for redundant apps:

                        #Calculator
                        for i in ~/.local/share/applications/waydroid.com.android.calculator2.desktop; do echo 'NoDisplay=true' >> $i; done

                        Camera

                        for i in ~/.local/share/applications/waydroid.com.android.camera2.desktop; do echo 'NoDisplay=true' >> $i; done

                        Contacts

                        for i in ~/.local/share/applications/waydroid.com.android.contacts.desktop; do echo 'NoDisplay=true' >> $i; done

                        Email

                        for i in ~/.local/share/applications/waydroid.com.android.email.desktop; do echo 'NoDisplay=true' >> $i; done

                        Clocks

                        for i in ~/.local/share/applications/waydroid.com.android.deskclock.desktop; do echo 'NoDisplay=true' >> $i; done

                        Dailer

                        for i in ~/.local/share/applications/waydroid.com.google.android.dialer.desktop; do echo 'NoDisplay=true' >> $i; done

                        Files

                        for i in ~/.local/share/applications/waydroid.com.android.documentsui.desktop; do echo 'NoDisplay=true' >> $i; done

                        Gallery

                        for i in ~/.local/share/applications/waydroid.com.android.gallery3d.desktop; do echo 'NoDisplay=true' >> $i; done

                        Music

                        for i in ~/.local/share/applications/waydroid.org.lineageos.eleven.desktop; do echo 'NoDisplay=true' >> $i; done

                        Browser

                        for i in ~/.local/share/applications/waydroid.org.lineageos.jelly.desktop; do echo 'NoDisplay=true' >> $i; done

                        Recorder

                        for i in ~/.local/share/applications/waydroid.org.lineageos.recorder.desktop; do echo 'NoDisplay=true' >> $i; done

                        Calendar

                        for i in ~/.local/share/applications/waydroid.org.lineageos.etar.desktop; do echo 'NoDisplay=true' >> $i; done

                        A 1 Reply Last reply Reply Quote 3
                        • A
                          aarontheissueguy @Guest last edited by

                          @xray2000 how exactly did you use those commands? Putting them into an sh file and running it doesnt seem to work

                          stanwood ? 2 Replies Last reply Reply Quote 0
                          • stanwood
                            stanwood @aarontheissueguy last edited by stanwood

                            @aarontheissueguy Just spoke with Xray right now, so open terminal and type:

                            sudo -s
                            sudo mount -o remount,rw /
                            for i in ~/.local/share/applications/waydroid.com.android.calculator2.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.com.android.camera2.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.com.android.contacts.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.com.android.email.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.com.android.deskclock.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.com.google.android.dialer.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.com.android.documentsui.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.com.android.gallery3d.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.org.lineageos.eleven.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.org.lineageos.jelly.desktop; do echo 'NoDisplay=true' >> $i; done$
                            for i in ~/.local/share/applications/waydroid.org.lineageos.recorder.desktop; do echo 'NoDisplay=true' >> $i; done
                            for i in ~/.local/share/applications/waydroid.org.lineageos.etar.desktop; do echo 'NoDisplay=true' >> $i; done
                            clear
                            reboot
                            

                            But not tested from my side!!!! Maybe test one of these commands and check if file is not shown anymore in your launcher. (don't forget to reboot device first)

                            Nexus 5 stable
                            If God has a computer, it must be a GNU/Linux

                            A 1 Reply Last reply Reply Quote 1
                            • ?
                              A Former User @aarontheissueguy last edited by

                              @aarontheissueguy Just ssh to your device and copy paste it line by line...

                              A 1 Reply Last reply Reply Quote 1
                              • A
                                aarontheissueguy @Guest last edited by

                                @xray2000 Thanks everything except contacts is gone. I think I will write an helper app to make that things discussed in this thread easier for the average user.

                                ? 1 Reply Last reply Reply Quote 1
                                • ?
                                  A Former User @aarontheissueguy last edited by A Former User

                                  @aarontheissueguy I made a mistake with the contacts line i have edit it now and update it.

                                  stanwood 1 Reply Last reply Reply Quote 1
                                  • stanwood
                                    stanwood @Guest last edited by stanwood

                                    @xray2000 Thank you Rudi. Post 12 updated accordingly.

                                    Nexus 5 stable
                                    If God has a computer, it must be a GNU/Linux

                                    1 Reply Last reply Reply Quote 0
                                    • A
                                      aarontheissueguy @stanwood last edited by aarontheissueguy

                                      @stanwood I wrote a small app to make this process easier. It shows you all the apps that waydroid installed and lets you hide it by swiping from left to right and show it again by swiping in the other direction.

                                      photo_2021-11-21_16-25-36.jpg

                                      photo_2021-11-21_16-26-07.jpg

                                      make sure to reload the appdrawer after any changes. That means scroll up all the way and swipe down. The changes should have taken effect now.

                                      This is very much bodged together but I plan to add more functionality and add it to the openstore eventually.

                                      Download: https://cloud.aaron.place/index.php/s/kd8FjCDsSWGTB4T

                                      open the click with openstore to install

                                      Keneda stanwood ? D 4 Replies Last reply Reply Quote 3
                                      • Keneda
                                        Keneda @aarontheissueguy last edited by

                                        @aarontheissueguy
                                        Why not publishing your app on the Openstore ?

                                        2015-Now : Meizu MX4 (Stable) for daily use
                                        Spare : Nexus 5 (Stable)

                                        A 1 Reply Last reply Reply Quote 0
                                        • A
                                          aarontheissueguy @Keneda last edited by

                                          @keneda Not tested much yet. And a few functions I still want to add.

                                          ? 1 Reply Last reply Reply Quote 0
                                          • stanwood
                                            stanwood @aarontheissueguy last edited by

                                            @aarontheissueguy Amazing. Congrats! Hope it will be added to the OpenStore ๐Ÿ˜‰

                                            Nexus 5 stable
                                            If God has a computer, it must be a GNU/Linux

                                            1 Reply Last reply Reply Quote 0
                                            • First post
                                              Last post