Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make mobile-install on windows #2

Closed
Oblivivious opened this issue Jun 15, 2024 · 8 comments
Closed

Make mobile-install on windows #2

Oblivivious opened this issue Jun 15, 2024 · 8 comments
Labels
help wanted Extra attention is needed

Comments

@Oblivivious
Copy link

Hi,
I have downloaded make using choco on windows. Then running 'make mobile-install' gives me:
tar: Option --transform=s,^scripts/,pixel-backup-gang-snapshot/, is not supported
Usage:
List: tar -tf
Extract: tar -xf
Create: tar -cf [filenames...]
Help: tar --help
make: *** [Makefile:42: pixel-backup-gang-snapshot.tar.gz] Error 1

(Could this be a limitation of the tar command on windows, no '--transform' option?)

I also have no idea on how to do the process on the pixel phone. I'm just really new to this, and probably need a step by step process. I just find the current process a bit difficult to wrap my head around. Especially where to copy the scripts and files, what I need and where to run the files. Like an ELI5 would be amazing for amateurs like me who want to get the most out of my pixel phone.

Thanks for the help

@master-hax
Copy link
Owner

the makefile only works on linux. you can instead manually copy the scripts to the device. the easiest way to do that is to download the latest release

@master-hax
Copy link
Owner

master-hax commented Jun 16, 2024

i added a new install script. you can run the following one liner from the pixel:

sh -c "$(curl -fSs https://raw.githubusercontent.com/master-hax/pixel-backup-gang/master/install.sh)"

@Oblivivious
Copy link
Author

Thanks for simplifying the process,
Do I have to separately find and mount the ssd,
or is there something I can do after
'''pixel backup gang successfully installed to /data/data/com.termux/files/home/pixel-backup-gang.'''

Im assuming it doesn't auto mount the ssd card as the os is still asking me to format the drive. In termux when I use:
bash show_devices.sh
It doesn't do anything for me (I was in the downloads directory after opening the shell script from file manager and the file was saved in ~/downloads/)

Thank you

@Oblivivious
Copy link
Author

I have installed many packages and in magisk, change mount namespace mode to global. and pasted all of the scripts to /data/data/com.termux/files/home/ as well as /data/data/downloads.

In termux I input:
su
./mount_ext4 ___
I get not running in global mount namespace, try elevating first

But the alternative:
su
./start_global_shell.sh
./mount_ext4.sh ____ or bash mount_ext4.sh
I get inaccessible or not found

If I do it from ~/downloads/ then nothing happens with all of the commands

@Oblivivious
Copy link
Author

This is pretty much what I did, I tried way more things so I don't know if that changed anything (I didn't document them as it didn't go anywhere).
Mind the layout, I tried my best, and it was reordered to group actions together for simplification, in contrast, my trial and error method had a much more sporadic ordering.
Let me know if I did anything wrong, or if you'd change anything.

______Setup
-Use MiniTool Partition Wizard to format the external drive to ext4 on Windows
-Install the repo onto the pixel phone
-Needs Magisk
-Download Termux from f-droid
-in an adb folder open up cmd
-In Termux type 'su' to get root permission from Magisk
-Go to settings (pixel phone) and in permissions give access to storage

-Type:
termux-setup-storage ***Dunno what this did tho but I did it so...

***Stuffs I installed
pkg install util-linux
pkg install tsu
pkg install blk-utils

***Switch repos ***if you are having problems installing the packages
termux-change-repo

_______Use to find external drive easier (By looking at file size)(use a new session (you can use two fingers to swipe from the left side)):
tsu
lsblk

***Look for the size of the drive/partition that closely matches your external drive (mine was sdg1) sdg should be at the very bottom

***The Block_device looks like: /dev/block/sdg1
(To me it looks more like a path) (Correct me if I'm wrong, it just seemed to work for me) (This took so long to figure out, ultimately it was luck and desparation, I tried literally everything.)


_______Download the files
su
sh -c "$(curl -fSs https://raw.githubusercontent.com/master-hax/pixel-backup-gang/master/install.sh)"

_____________mount external drive
su
cd /data/data/com.termux/files/home/downloads
./start_global_shell.sh
cd /data/data/com.termux/files/home/downloads
./mount_ex4.sh /dev/block/sdg1

***Then I'm assuming that the the_binding folder is what I use to backup to and from.
Would like clarification if there are any other indications that this worked. As I cannot see any other indication and the notification "Issue with drive, tap to fix" is still there.

@master-hax
Copy link
Owner

you don't need to do any of that extra stuff...you don't even need termux. just run the scripts as root.

yes, /the_binding on the internal "sd card" is mirrored to the one on the external drive

@Oblivivious
Copy link
Author

Oblivivious commented Jun 19, 2024

I have zero clue how to "run the scripts as root", (without a terminal?) I don't think the files app or mixplorer has that capability.
Anyway, what I did before didn't work so I had to do it all over again, and here is the refined documentation of my steps for dumb dumbs like me.

All assuming you already have:
magisk and rooted
termux downloaded from fdroid

-Process in termux:
pkg install tsu
pkg install blk-utils
tsu (Random note: I dunno if you need to do 'su' before this to get root)
lsblk (Take note of the name/identifier of the partition with a similar storage size as your external drive)
su
sh -c "$(curl -fSs https://raw.githubusercontent.com/master-hax/pixel-backup-gang/master/install.sh)"
cd /data/data/com.termux/files/home/pixel-backup-gang
./start_global_shell.sh
cd /data/data/com.termux/files/home/pixel-backup-gang
./mount_ext4.sh /dev/block/sdi1
^(dependent on what you see from lsblk, look at the one with the most similar file size as your
external drive mine this time was sdi1 - this may change everytime you mount a drive)

Then, you can look into your internal storage and create a folder/transfer a file into the the_binding folder to check if it works. (I couldn't find the internal storage on google files so I used mixplorer, you can use any file explorer, its just up to your preference).

You can mark this issue as complete. Ideally, add something like this as a part of the installation documentation, for the dumb dumbs like me who don't know what to do, and need step by step instructions. I actually don't know if this is the correct way of doing it. Please correct me if I am wrong in any step. It would be comforting to have someone who knows what they are doing give the instructions.

@master-hax
Copy link
Owner

master-hax commented Jun 19, 2024

Everything before su is unnecessary. All the steps after su look correct to me. Note that lsblk doesn't work without su.

Glad you got it working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants