UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Copy or cut with terminal

    Scheduled Pinned Locked Moved Support
    6 Posts 2 Posters 477 Views 1 Watching
    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.
    • D Offline
      domubpkm
      last edited by

      If I understand correctly, the only way that currently should work with the Pinephone to copy or cut a file from one directory to another is to use the terminal. This way should also work with all UT smartphones.
      I tried different usual syntaxes on UT smartphones (Pinephone RC, OPO DEV ) and it doesn't work and I don't understand why!
      Dossier A Dossier B 20200917_143338592.png
      Dossier A certif 20200917_143352860.png

      An example: considering Folder A and Folder B, (screenshots as a basis for the example), which are the right synthaxes to copy certificate.pdf from Folder A to Folder B or move certificate.pdf to Folder B?
      Ps: please check that this works well (in DEV or RC ) before your feedback !
      In advance, thank you very much !!

      arubislanderA 1 Reply Last reply Reply Quote 0
      • arubislanderA Offline
        arubislander @domubpkm
        last edited by arubislander

        @domubpkm: It would have helped those trying to help if you had shown what you had already tried and what were the error messages, if any. Saves others from trying the same, or else helps us see where it might have gone wrong. As it is now, trying to help feels like setting out on some kind of treasure hunt.

        (For those, as I was, not aware of why a simple copy / paste in the File Manager app doesn't work on the PinePhone: Pasting seems to cause Lomiri to crash)

        To copy certificat.pdf from ~/Documents/Dossier A to ~/Documents/Dossier B try the following in the Terminal app:

        ~$ cp ~/Documents/Dossier\ A/certificat.pdf ~/Documents/Dossier\ B 
        

        to move the file instead:

        ~$ mv ~/Documents/Dossier\ A/certificat.pdf ~/Documents/Dossier\ B 
        

        The issue here I think is the space in the folder name. This needs to be escaped. It can be done with the \ character, or by enclosing the folder name within double quotes. But in general use of spaces is discouraged in folder names, as it can be somewhat inconvenient on the command line. You could consider using underscores (_) instead.

        πŸ‡¦πŸ‡Ό πŸ‡³πŸ‡± πŸ‡ΊπŸ‡Έ πŸ‡ͺπŸ‡Έ
        Happily running Ubuntu Touch
        JingPad (24.04-1.x daily)
        OnePlus Nord N10 5G (24.04-2.x daily)
        PinePhone OG (20.04)
        Meizu Pro 5 (16.04 DEV)

        D 1 Reply Last reply Reply Quote 2
        • D Offline
          domubpkm @arubislander
          last edited by

          @arubislander Currently tested on BQ E5 HD dev : ONLY double quotes work . I will test more tonight.
          Thank you.

          1 Reply Last reply Reply Quote 0
          • D Offline
            domubpkm
            last edited by

            Not specifically to my problem, but confirmation that generally speaking, the cp and mv commands work well in the Pinephone! πŸ™‚

            1 Reply Last reply Reply Quote 0
            • arubislanderA Offline
              arubislander
              last edited by

              Command line tools that manipulate the filesystem will tend to work on any distribution. If you can pull up a terminal, the screen is legible and the (on screen) keyboard responds to what you type, then you are usually good to go.
              Only thing like missing packages or incorrectly configured permissions, will be able to foil you now and then. But those instances are rare.

              πŸ‡¦πŸ‡Ό πŸ‡³πŸ‡± πŸ‡ΊπŸ‡Έ πŸ‡ͺπŸ‡Έ
              Happily running Ubuntu Touch
              JingPad (24.04-1.x daily)
              OnePlus Nord N10 5G (24.04-2.x daily)
              PinePhone OG (20.04)
              Meizu Pro 5 (16.04 DEV)

              D 1 Reply Last reply Reply Quote 0
              • D Offline
                domubpkm @arubislander
                last edited by

                @arubislander The usefulness of the cp and mv commands is that they can be currently being used as a workaround for a very annoying bug on the Pinephone : https://gitlab.com/ubports/community-ports/pinephone/-/issues/53

                1 Reply Last reply Reply Quote 0

                Hello! It looks like you're interested in this conversation, but you don't have an account yet.

                Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

                With your input, this post could be even better πŸ’—

                Register Login
                • First post
                  Last post