So I see people have trouble using apk manager, apk tool or the signing tool. This solves that simple double click the one_click_signer.cmd and give the name and path of your zip or apk and BAM!!! it gets signed and zipaligned.
You'll need java in your class path for this to work orrr alter the script to point to where java is on your machine.
hopefully this one works for me.. java has been in my class path for others, but could never figure out where things went wrong...
I can answer any Java question you have... class path, Mem settings
Sent from my PC36100 using XDA App
thanks, working for me!
Use Zipsigner instead
Sent from my X8
hopefully this one works for me too..
How i do in UNIX??
useless
ASimmons said:
...give the name and path of your zip or apk and BAM!!! it gets signed and zipaligned...
Click to expand...
Click to collapse
Maybe others would work with proper tweaking of environment variables, but One Click Signer is the first solution that worked for me! However, I could not get it to work by providing any name & path such as C:\myapp.apk or even what the prompt literally asks for- myapp.apk C:\. What finally worked through trial & error was to just have the apk in the same directory as one_click_signer.cmd and specify ONLY the apk name (as in myapp.apk). I'm not positive, but spaces in paths or file names are probably best avoided as well.
Thank you so much man I can now test my app skipping google's requirements.
very useful. I had problems signing apks and this did the trick.
Hello.
Very nice tutorial, i just find it easier to do it like this:
1. Download the rar and extract the lib folder somewhere
2. Copy your APK or ZIP to the lib folder
3. Press shift and rightclick in the folder (not on a file) - select "open command prompt here"
4. To sign a file: java -Xmx512m -jar signapk.jar -w testkey.x509.pem testkey.pk8 <APK OR ZIP NAME> <APK OR ZIP NAME> (example java -Xmx512m -jar signapk.jar -w testkey.x509.pem testkey.pk8 myfile.apk myfile.apk
5. To zipalign the file: zipalign -f 4 <APK OR ZIP NAME> <APK OR ZIP NAME> (example: zipalign -f 4 myfile.apk myfile.apk)
Done!
The reason for this approch is that you are 100% sure it will work, because you are working directly in the directory.
monchyrcg said:
How i do in UNIX??
Click to expand...
Click to collapse
Linux:
Code:
[email protected]:~/android/apktool$ cat one_click_signer/one_click_signer.sh
export EnableDelayedExpansion # dunno what that does
if [ -z $1 ]; then
echo "usage: $0 xxx.apk"
exit 2
fi
ROM=$1
cp $ROM x$ROM
cd lib
# sign the rom
java -Xmx512m -jar signapk.jar -w testkey.x509.pem testkey.pk8 ../$ROM ../x$ROM
# zip align
./zipalign -f 4 ../x$ROM ../signed-$ROM
cd ..
rm x$ROM
copy zipalign from ~/android-sdk-linux_x86/tools/
sh-06d nerv only Docomo launcher Rom oficial
Hello good friends and found the files in the official ROM released for the phone sh-06d nerv only here you will find all the content of the wallpapers Ringtones equipment and just about anything to have hope and someone decides to port it to other teams in this community so great there are people who really like to share their knowledge and would love to work together to carry this Rom for other teams doing well and something that many users have asked seen shouting greetings and look forward to your support here I left the Link http://tieba.baidu.com/p/2012713251
Finally, a program that worked. Good work.
I am new to android i dont know any thing please help
ASimmons said:
So I see people have trouble using apk manager, apk tool or the signing tool. This solves that simple double click the one_click_signer.cmd and give the name and path of your zip or apk and BAM!!! it gets signed and zipaligned.
You'll need java in your class path for this to work orrr alter the script to point to where java is on your machine.
Click to expand...
Click to collapse
for this post i want say that i have a java installed in my windows xp can any one send me a video tutorial on how to use one click signer.
my email id is [email protected]
---------- Post added at 11:23 AM ---------- Previous post was at 11:19 AM ----------
ASimmons said:
So I see people have trouble using apk manager, apk tool or the signing tool. This solves that simple double click the one_click_signer.cmd and give the name and path of your zip or apk and BAM!!! it gets signed and zipaligned.
You'll need java in your class path for this to work orrr alter the script to point to where java is on your machine.
Click to expand...
Click to collapse
You'll need java in your class path
What does that mean i have a java installed on xp please help or send a video.
easiest way is to just drag apk file into one click dailog box. .and press enter......it will do the rest itself....i wish unity 4+ were also open sourcd...
The script only works if you put apk/zip in script folder. I rewrote the script. Open the cmd file and replace all text with this one:
Code:
@ECHO off
setlocal EnableDelayedExpansion
SET SCRIPT_PATH=%0
SET SCRIPT_PATH=%SCRIPT_PATH:"=%
echo %SCRIPT_PATH% | FIND ":" > nul
IF %ERRORLEVEL%==1 SET SCRIPT_PATH=%CD%\%SCRIPT_PATH%
FOR /F "delims=\ tokens=*" %%G IN ('echo %SCRIPT_PATH%') DO SET SCRIPT_PATH=%%~dpG
SET SCRIPT_PATH=%SCRIPT_PATH:~0,-1%
if NOT "%1"=="" goto seguir
echo Enter full path and filename of the apk/zip to sign or drag&drop file to this window:
SET /P rom=----^>?
call :separar "%ROM%"
goto seguir2
:seguir
call :separar "%1"
:seguir2
echo Copying "%ruta%%archivo%" to "%ruta%temp-%archivo%"
copy "%ruta%%archivo%" "%ruta%temp-%archivo%">nul
set olddir=%cd%
cd /d "%SCRIPT_PATH%\lib"
echo Signing "%ruta%temp-%archivo%"
java -Xmx512m -jar signapk.jar -w testkey.x509.pem testkey.pk8 "%ruta%temp-%archivo%" "%ruta%temp-%archivo%"
echo Zip aligning "%ruta%temp-%archivo%" to "%ruta%signed-%archivo%"
zipalign -f 4 "%ruta%temp-%archivo%" "%ruta%signed-%archivo%"
del "%ruta%temp-%archivo%"
cd /d "%olddir%"
goto fin
:separar
set ruta=%~dp1
set archivo=%~nx1
goto :eof
:fin
This works in the folllowing cases:
- Calling script from command line (from any drive/folder)
- Calling it from Windows (Explorer/Run/etc)
And you can pass apk/zip in the following ways:
- Drag&drop file to the console window
- Passing file as an argument
- Manually writing full path and filename to file
Bye and sorry for my english.
PLAY STORE SAYS ::
Upload failed
You uploaded an APK that is signed with a restricted certificate. You need to upload an APK signed with your own certificate.
PLEASE UPDATE THE CERTIFICATE FILES
Right-Click Menu?
I created .reg file to add this "apksign one click" to mouse right click menu (when i click r-click on apk, will give me sign apk).
SEE the BOLD part..i get the menu but it dont work i got error...later ill show you
Code:
@echo off
color 0a
:: relaunch self elevated
ver|find /i "XP">nul||whoami /all|find "S-1-16-12288">nul
IF %ERRORLEVEL% NEQ 0 (
echo Set UAC = CreateObject^("Shell.Application"^) > "%temp%\getadmin.vbs"
echo UAC.ShellExecute "%~s0", "", "", "runas", 1 >> "%temp%\getadmin.vbs"
"%temp%\getadmin.vbs"
del "%temp%\getadmin.vbs"
exit /B
)
java -version >nul 2>&1||echo Error: Java is not found&&echo Please install JRE first &&echo.&&echo Existing..&&pause&&exit
:: remove menu handlers installed by other apps
reg add "HKCR\.apk" /f /ve /t REG_SZ /d ""
reg delete "HKCU\Software\Classes\.apk" /f >nul 2>&1
reg delete "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.apk" /f >nul 2>&1
reg add "HKCR\.apk\DefaultIcon" /f /ve /t REG_SZ /d "%~dp0tools\apk.ico"
reg add "HKCR\.apk\shell\decompile" /f /ve /t REG_SZ /d "Browse Java Code of APK"
reg add "HKCR\.apk\shell\decompile\command" /f /ve /t REG_SZ /d "\"%~dp0tools\decompile.cmd\" \"%%1\""
reg add "HKCR\.apk\shell\disassemble" /f /ve /t REG_SZ /d "Disassemble APK and Decode Resources"
reg add "HKCR\.apk\shell\disassemble\command" /f /ve /t REG_SZ /d "\"%~dp0tools\disassemble.cmd\" \"%%1\""
reg add "HKCR\.apk\shell\install" /f /ve /t REG_SZ /d "Install APK to Phone"
reg add "HKCR\.apk\shell\install\command" /f /ve /t REG_SZ /d "\"%~dp0tools\install.cmd\" \"%%1\""
[U]reg add "HKCR\.apk\shell\signapk" /f /ve /t REG_SZ /d "Sign the Apk"
reg add "HKCR\.apk\shell\signapk" /f /ve /t REG_SZ /d "\"%~dp0tools\oneclickapksigner.cmd\" \"%%1\""[/B][/U]
reg add "HKCR\folder\shell\recompile" /f /ve /t REG_SZ /d "Recompile APK from Disassembly"
reg add "HKCR\folder\shell\recompile\command" /f /ve /t REG_SZ /d "\"%~dp0tools\buildapk.cmd\" \"%%1\""
:: remove entries left from old versions
reg delete "HKCR\jarfile\shell\decompile" /f >nul 2>&1
pause
#android-shot
#your one stop screenshot solution!
#screenshot recovery for windows!
#screenshot system for windows!
#video_record recovery for windows!
#video_record system for windows!
Looking for a Linux Version???
Go Here: http://forum.xda-developers.com/showthread.php?t=2260704
This solely uses the SD Card, which, by default is always kept mounted by
a partition. So, you wouldn't run into any trouble except when you try to
partition or format the SD Card.
I repeat, no need to mount any partition... By default, the SD Card is always mounted, so, I thought using it will be way better than using the /data partition
To take a screenshot:
Code:
Run "shot.bat"
Your screenshot will be saved in a folder named screenshots automatically.
To capture video:
Code:
Run "record.bat"
Press "Ctrl+C" when you have finished recording.
This will basically start recording your screen frame by frame, and automatically
save it in your SD card. Note that recording the video alone is not enough.
Do the following to pull those frames from the SD card, and make a video out of them.
Code:
Run "mkvideo.bat"
Enter the Name that you want to name your video. DON'T ADD AN EXTENSION!
The files will be collected from the SD Card, and a video will be made out
of them. Then, the temporary files will be cleaned automatically, from both
your SD card, and your system.
Downloads:
Version 2.1 (GUI) (Android-Andi): http://forum.xda-developers.com/showpost.php?p=45891403&postcount=59
Version 2.1.3 (Android-Andi): http://forum.xda-developers.com/showpost.php?p=44447366&postcount=40
Version 2.1.2 (Android-Andi): http://forum.xda-developers.com/showpost.php?p=44288806&postcount=36
Version 2.0.1 (Android-Andi): http://forum.xda-developers.com/showpost.php?p=44011267&postcount=17
Version 2.0 (Thanks to Android-Andi): http://forum.xda-developers.com/showpost.php?p=43982996&postcount=12
Version 1.0: http://www.mediafire.com/download/26gi88xdd5c6rly/android-shot_windows.zip
Note: A GUI version can be found here: http://forum.xda-developers.com/showpost.php?p=45891403&postcount=59
Not personally tested by me, as I don't have the appropriate tools (i.e. windows) no more...
Credits:
Kyan He (https://plus.google.com/116857119889961125943) and his wonderful tool "fb2png" (https://code.google.com/p/android-fb2png/)
Whiskey103 (http://forum.xda-developers.com/member.php?u=2632943) and his guide (http://forum.xda-developers.com/showthread.php?p=40260716) on taking screenshot in windows.
Android-Andi (http://forum.xda-developers.com/member.php?u=5153662) for version 2.0 and some cool ideas
Sample:
Recovery!
Recovery & System Video Sample! [With instructions ]
not working and said
"ECHO off 'and' is not recognized as an internal or external command, operable program or batch file.
'C:\Doccuments' is not recognized as an internal or external command, operable program or batch file.
will try your linux version, when get home
Strange....
antutu said:
not working and said
"ECHO off 'and' is not recognized as an internal or external command, operable program or batch file.
'C:\Doccuments' is not recognized as an internal or external command, operable program or batch file.
will try your linux version, when get home
Click to expand...
Click to collapse
Anyways, thanks for your report
I will look into it, as soon as possible
P.S. Only problem is... I don't have Windows :silly: So, it would be a beta :angel:
vineethraj49 said:
Anyways, thanks for your report
I will look into it, as soon as possible
P.S. Only problem is... I don't have Windows :silly: So, it would be a beta :angel:
Click to expand...
Click to collapse
Take your time mate:thumbup:
Sorry bro i just found out how this can work out
I've to put it in root folder
It's working great now:thumbup::thumbup:
Thanks al lot! That´s what i was looking for.
I tried to get better Video-Quality (libx264 as *.mp4).
I modified the .bat
Code:
ECHO off
REM snaps mode
REM fb2png credits go to respective developers
REM thanks to whiskey103 for his screenshot.bat for windows
REM thanks to vineethraj49 for his mkvideo.bat (video as *.avi)
REM thanks to me and my computer
IF EXIST %~dp0tmp ECHO tmp directory found! :)
IF NOT EXIST %~dp0tmp ECHO tmp directory not found! :( && MKDIR tmp && ECHO initialised new tmp directory! :)
IF EXIST %~dp0output_video ECHO output_video directory found! :)
IF NOT EXIST %~dp0output_video ECHO output_video directory not found! :( && MKDIR output_video && ECHO initialised new output_video directory! :)
%~dp0tools\adb pull /sdcard/fb2png/screens/ tmp
SET /P name=Enter the name for your video:
%~dp0tools\ffmpeg.exe -f image2 -r 2 -i tmp/1%%09d.png -c:v libx264 -r 30 output_video/%name%.mp4
%~dp0tools\adb shell rm /sdcard/fb2png/screens/*
rm tmp/*
REM hit enter to exit
pause
Someone knows how to make the quality better then with my modified bat?
Me again:
To use your shot.bat i had to download 2 *.dll´s to get "date.exe" working (libiconv2.dll and libintl3.dll). Without these .dll screenshot not possible.
Maybe you can add these two *.dll into your tool directory (don´t know if it´s allowed, check it here).
Download (GnuWin) Libintl.exe(?) from here and install it.
You´ll find the 2 needed *.dll at "C:\Program Files (x86)\GnuWin32\bin".
I´m, running Windows 8 Pro.
Maybe you can add (after changeing directory path) my modified "record.bat" for taking screenshots from running androidsystem
Code:
@ECHO off
REM Record_running_Android
IF EXIST %~dp0new ECHO new directory found! :)
IF NOT EXIST %~dp0new ECHO new directory not found! :(
mkdir new
ECHO initialised new directory! :)
:loop
%~dp0tools\adb shell screencap -p /extSdCard/screen.png
%~dp0tools\adb pull /extSdCard/screen.png %~dp0new
%~dp0tools\adb shell rm /extSdCard/screen.png
FOR /F "tokens=*" %%i in ('%~dp0tools\date.bat') do SET DATE=%%i
MOVE %~dp0new\screen.png %~dp0new\%DATE%.png
goto loop
pause
I´m using extSdCard as directory, because my Micro-SD-Card is mounted there.
Maybe change it like this:
Code:
@ECHO off
REM Record_running_Android
IF EXIST %~dp0new ECHO new directory found! :)
IF NOT EXIST %~dp0new ECHO new directory not found! :(
mkdir new
ECHO initialised new directory! :)
:loop
%~dp0tools\adb shell screencap -p /sdcard/screen.png
%~dp0tools\adb pull /sdcard/screen.png %~dp0new
%~dp0tools\adb shell rm /sdcard/screen.png
FOR /F "tokens=*" %%i in ('%~dp0tools\date.bat') do SET DATE=%%i
MOVE %~dp0new\screen.png %~dp0new\%DATE%.png
goto loop
pause
Whoa! Someone actually cares
Android-Andi said:
Thanks al lot! That´s what i was looking for.
I tried to get better Video-Quality (libx264 as *.mp4).
I modified the .bat
Code:
ECHO off
REM snaps mode
REM fb2png credits go to respective developers
REM thanks to whiskey103 for his screenshot.bat for windows
REM thanks to vineethraj49 for his mkvideo.bat (video as *.avi)
REM thanks to me and my computer
IF EXIST %~dp0tmp ECHO tmp directory found! :)
IF NOT EXIST %~dp0tmp ECHO tmp directory not found! :( && MKDIR tmp && ECHO initialised new tmp directory! :)
IF EXIST %~dp0output_video ECHO output_video directory found! :)
IF NOT EXIST %~dp0output_video ECHO output_video directory not found! :( && MKDIR output_video && ECHO initialised new output_video directory! :)
%~dp0tools\adb pull /sdcard/fb2png/screens/ tmp
SET /P name=Enter the name for your video:
%~dp0tools\ffmpeg.exe -f image2 -r 2 -i tmp/1%%09d.png -c:v libx264 -r 30 output_video/%name%.mp4
%~dp0tools\adb shell rm /sdcard/fb2png/screens/*
rm tmp/*
REM hit enter to exit
pause
Someone knows how to make the quality better then with my modified bat?
Click to expand...
Click to collapse
Remember that the *quality* is always the same. It pulls the images (frames) in the same resolution as of your phone. If you are talking about the FPS, you should modify this line...
Code:
ffmpeg -r 4
The -r switch controls the FPS.
Again, the FPS depends upon how many screens are actually captured by your device. If you have a fast SD-Card, and a fast processor, it is indeed likely that the frames captured would be more. You can try increasing the -r 4 by 2/3 frames and see if the video is suitable to your needs. (eg. -r 5/ -r 6, etc...)
Android-Andi said:
Me again:
To use your shot.bat i had to download 2 *.dll´s to get "date.exe" working (libiconv2.dll and libintl3.dll). Without these .dll screenshot not possible.
Maybe you can add these two *.dll into your tool directory (don´t know if it´s allowed, check it here).
Download (GnuWin) Libintl.exe(?) from here and install it.
You´ll find the 2 needed *.dll at "C:\Program Files (x86)\GnuWin32\bin".
I´m, running Windows 8 Pro.
Click to expand...
Click to collapse
Didn't know about that... It worked for me without those two DLLs. Anyways, I will just add it for safety.
Android-Andi said:
Maybe you can add (after changeing directory path) my modified "record.bat" for taking screenshots from running androidsystem
Code:
@ECHO off
REM Record_running_Android
IF EXIST %~dp0new ECHO new directory found! :)
IF NOT EXIST %~dp0new ECHO new directory not found! :(
mkdir new
ECHO initialised new directory! :)
:loop
%~dp0tools\adb shell screencap -p /extSdCard/screen.png
%~dp0tools\adb pull /extSdCard/screen.png %~dp0new
%~dp0tools\adb shell rm /extSdCard/screen.png
FOR /F "tokens=*" %%i in ('%~dp0tools\date.bat') do SET DATE=%%i
MOVE %~dp0new\screen.png %~dp0new\%DATE%.png
goto loop
pause
I´m using extSdCard as directory, because my Micro-SD-Card is mounted there.
Maybe change it like this:
Code:
@ECHO off
REM Record_running_Android
IF EXIST %~dp0new ECHO new directory found! :)
IF NOT EXIST %~dp0new ECHO new directory not found! :(
mkdir new
ECHO initialised new directory! :)
:loop
%~dp0tools\adb shell screencap -p /sdcard/screen.png
%~dp0tools\adb pull /sdcard/screen.png %~dp0new
%~dp0tools\adb shell rm /sdcard/screen.png
FOR /F "tokens=*" %%i in ('%~dp0tools\date.bat') do SET DATE=%%i
MOVE %~dp0new\screen.png %~dp0new\%DATE%.png
goto loop
pause
Click to expand...
Click to collapse
You could change it yourself... Reason why I wouldn't change it? Because different devices have different mount points. If it is extSDcard, you can change accordingly. (If that wasn't the point, please clarify the last post. I understood it as: my mountpoint for sdcard is different :silly
p.s. thanks.. i was thinking no one cared
vineethraj49 said:
Remember that the *quality* is always the same. It pulls the images (frames) in the same resolution as of your phone. If you are talking about the FPS, you should modify this line...
Code:
ffmpeg -r 4
The -r switch controls the FPS.
Again, the FPS depends upon how many screens are actually captured by your device. If you have a fast SD-Card, and a fast processor, it is indeed likely that the frames captured would be more. You can try increasing the -r 4 by 2/3 frames and see if the video is suitable to your needs. (eg. -r 5/ -r 6, etc...)
Click to expand...
Click to collapse
This will change how long the picture stays (i set it down to 2, beacause in my case it was to fast).
MP4 and libx264 codec will give you better quality. I tested it yesterday the whole evening Trust me. Screenshot added (mp4 more clearly).
Try that one (video looks better):
Code:
ECHO off
REM snaps mode
REM fb2png credits go to respective developers
REM thanks to whiskey103 for his screenshot.bat for windows
REM thanks to vineethraj49 for his mkvideo.bat (video as *.avi)
REM thanks to me and my computer
IF EXIST %~dp0tmp ECHO tmp directory found! :)
IF NOT EXIST %~dp0tmp ECHO tmp directory not found! :( && MKDIR tmp && ECHO initialised new tmp directory! :)
IF EXIST %~dp0output_video ECHO output_video directory found! :)
IF NOT EXIST %~dp0output_video ECHO output_video directory not found! :( && MKDIR output_video && ECHO initialised new output_video directory! :)
%~dp0tools\adb pull /sdcard/fb2png/screens/ tmp
SET /P name=Enter the name for your video:
%~dp0tools\ffmpeg.exe -f image2 -r 2 -i tmp/1%%09d.png -c:v libx264 -r 30 output_video/%name%.mp4
%~dp0tools\adb shell rm /sdcard/fb2png/screens/*
rm tmp/*
REM hit enter to exit
pause
vineethraj49 said:
Didn't know about that... It worked for me without those two DLLs. Anyways, I will just add it for safety.
Click to expand...
Click to collapse
Adding will take you on the safe side Thanks I think they are under GPLv2, but i´m not shure.
You can also download libiconv-1.9.2-1-bin.zip and libintl-0.14.4-bin.zip. DLL´s are in the "bin" directory after extracting.
vineethraj49 said:
You could change it yourself... Reason why I wouldn't change it? Because different devices have different mount points. If it is extSDcard, you can change accordingly. (If that wasn't the point, please clarify the last post. I understood it as: my mountpoint for sdcard is different :silly
Click to expand...
Click to collapse
Code:
[user=279333]@ECHO[/user] off
REM Record_running_Android
IF EXIST %~dp0new ECHO new directory found! :)
IF NOT EXIST %~dp0new ECHO new directory not found! :(
mkdir new
ECHO initialised new directory! :)
:loop
%~dp0tools\adb shell screencap -p /sdcard/screen.png
%~dp0tools\adb pull /sdcard/screen.png %~dp0new
%~dp0tools\adb shell rm /sdcard/screen.png
FOR /F "tokens=*" %%i in ('%~dp0tools\date.bat') do SET DATE=%%i
MOVE %~dp0new\screen.png %~dp0new\%DATE%.png
goto loop
pause
Internal SD? Same path you use in your batch-scripts. Should work for everyone.
[The Script i posted before was for use on micro-sd (working for my device) - i have changed it later ( ) to use on internal-sd for everyone]
Only one problem: the name of the files... can´t use the mkvideo.bat to make a video... i had to rename them after captureing using Ant Renamer2.
But you can add the 2 .bat from me as a "Bonus" into your zip if you want.
Sure!
Android-Andi said:
This will change how long the picture stays (i set it down to 2, beacause in my case it was to fast).
MP4 and libx264 codec will give you better quality. I tested it yesterday the whole evening Trust me. Screenshot added (mp4 more clearly).
Try that one (video looks better):
Code:
ECHO off
REM snaps mode
REM fb2png credits go to respective developers
REM thanks to whiskey103 for his screenshot.bat for windows
REM thanks to vineethraj49 for his mkvideo.bat (video as *.avi)
REM thanks to me and my computer
IF EXIST %~dp0tmp ECHO tmp directory found! :)
IF NOT EXIST %~dp0tmp ECHO tmp directory not found! :( && MKDIR tmp && ECHO initialised new tmp directory! :)
IF EXIST %~dp0output_video ECHO output_video directory found! :)
IF NOT EXIST %~dp0output_video ECHO output_video directory not found! :( && MKDIR output_video && ECHO initialised new output_video directory! :)
%~dp0tools\adb pull /sdcard/fb2png/screens/ tmp
SET /P name=Enter the name for your video:
%~dp0tools\ffmpeg.exe -f image2 -r 2 -i tmp/1%%09d.png -c:v libx264 -r 30 output_video/%name%.mp4
%~dp0tools\adb shell rm /sdcard/fb2png/screens/*
rm tmp/*
REM hit enter to exit
pause
Adding will take you on the safe side Thanks I think they are under GPLv2, but i´m not shure.
You can also download libiconv-1.9.2-1-bin.zip and libintl-0.14.4-bin.zip. DLL´s are in the "bin" directory after extracting.
Code:
[user=279333]@ECHO[/user] off
REM Record_running_Android
IF EXIST %~dp0new ECHO new directory found! :)
IF NOT EXIST %~dp0new ECHO new directory not found! :(
mkdir new
ECHO initialised new directory! :)
:loop
%~dp0tools\adb shell screencap -p /sdcard/screen.png
%~dp0tools\adb pull /sdcard/screen.png %~dp0new
%~dp0tools\adb shell rm /sdcard/screen.png
FOR /F "tokens=*" %%i in ('%~dp0tools\date.bat') do SET DATE=%%i
MOVE %~dp0new\screen.png %~dp0new\%DATE%.png
goto loop
pause
Internal SD? Same path you use in your batch-scripts. Should work for everyone.
[The Script i posted before was for use on micro-sd (working for my device) - i have changed it later ( ) to use on internal-sd for everyone]
Only one problem: the name of the files... can´t use the mkvideo.bat to make a video... i had to rename them after captureing using Ant Renamer2.
But you can add the 2 .bat from me as a "Bonus" into your zip if you want.
Click to expand...
Click to collapse
cool! i have no objection. as of mp4 encoding too, you could add it as a feature, but do release it in this thread only. I sure would give you credits for a version 2.0 :angel: i don't want xda to be weeded by one more thread. there are already many (by a gazillion n00bs )
I did some cool batch-scripts (modified scripts from yours). You can download from here. Extract and copy the *.bat into the android-shot folder.
What have i done?
E.g. you can set a different path for storing the *.png on your device untill they get pulled. You can also change the destination-folder (on your local computer).
(All codes only from line 7 to ~ line 15 in batch-script)
1. batch: screenshot_recovery-universal.bat
Click to expand...
Click to collapse
Code:
REM Please enter the path where your internalstorage or micro-SD is mounted in recovery
[COLOR="Red"]set extpath=/sdcard[/COLOR]
REM
REM E.g. set "extpath=/extSdCard" if your micro-sd is mounted at /extSdCard.
REM (default-path: /sdcard for internal storage)
REM
REM
REM Please enter the name of your destinationfolder on your computer:
[COLOR="Red"]set pngpath=screenshots[/COLOR]
REM (default-path:screenshots)
Mountpoint of micro SD is different on any devices, you can change it to your´s.
You can change also the destination folder - but leave it as it is If you do: you have to change it in the converting-video batch-script too.
2. batch: record_recovery-universal.bat
Click to expand...
Click to collapse
Code:
REM Please enter the path where your internalstorage or micro-SD is mounted in recovery:
[COLOR="Red"]set extpath=/sdcard[/COLOR]
REM e.g. set "extpath=/external_sd" if your micro-sd is mounted IN RECOVERY at /external_sd
REM (default-path: /sdcard for internal storage)
Mountpoint of micro SD is different on any devices, you can change it to your´s.
3. batch: record_running_android-universal.bat
Click to expand...
Click to collapse
Code:
REM Please enter the path where your internalstorage or micro-SD is mounted:
[COLOR="Red"]set extpath=/sdcard[/COLOR]
REM E.g. set "extpath=/extSdCard" if your micro-sd is mounted at /extSdCard
REM (default-path: /sdcard for internal storage)
REM
REM
REM
REM Please enter the name of your destinationfolder on your computer:
[COLOR="Red"]set destpath=tmpandroid[/COLOR]
REM (default-path: tmpandroid)
Mountpoint of micro SD is different on any devices, you can change it to your´s.
You can change also the destination folder - but leave it as it is If you do: You have to change it in the converting-video batch-script too.
4. batch: mkvideo_mp4_recovery-universal.bat
Click to expand...
Click to collapse
Code:
REM Please enter the path where your internalstorage or micro-SD is mounted in recovery
[COLOR="Red"]set extpath=/sdcard[/COLOR]
REM e.g. set "extpath=/external_sd" if your micro-sd is mounted IN RECOVERY at /external_sd
REM (default-path: /sdcard for internal storage)
REM
REM
REM Please enter the name of your png-folder on your computer
REM (same as "destpath" in record_recovery-universal.bat)
[COLOR="Red"]set pngpath=tmp[/COLOR]
REM (default-path:tmp - if you have modified the path do the same here)
Mountpoint of micro SD is different on any devices, you can change it to your´s. If you have changed it in the record_recover-batch-script - you have to do it too.
You can change also the destination folder - but leave it as it is If you have changed it in the record_recovery-batch-script - you have to do it too.
5. batch: mkvideo_mp4_running_android-universal.bat
Click to expand...
Click to collapse
Code:
REM Please enter the name of your png-folder on your computer
REM (same as "destpath" in record_runnning_android-universal.bat)
[COLOR="Red"]set pngpath=tmpandroid[/COLOR]
REM (default-path:tmpandroid - if you have modified the path do the same here)
You can change also the png folder - but leave it as it is If you have changed it in the record_running_android-batch-script - you have to do it too.
Please use Notepad++ if you want to change something in the batch-script.
For watching the .mp4 you can use Media Player Home Cinema.
Cool, but, one small change that I would like to say...
Android-Andi said:
I did some cool batch-scripts (modified scripts from yours). You can download from here. Extract and copy the *.bat into the android-shot folder.
What have i done?
E.g. you can set a different path for storing the *.png on your device untill they get pulled. You can also change the destination-folder (on your local computer).
(All codes only from line 7 to ~ line 15 in batch-script)
Code:
REM Please enter the path where your internalstorage or micro-SD is mounted in recovery
[COLOR="Red"]set extpath=/sdcard[/COLOR]
REM
REM E.g. set "extpath=/extSdCard" if your micro-sd is mounted at /extSdCard.
REM (default-path: /sdcard for internal storage)
REM
REM
REM Please enter the name of your destinationfolder on your computer:
[COLOR="Red"]set pngpath=screenshots[/COLOR]
REM (default-path:screenshots)
Mountpoint of micro SD is different on any devices, you can change it to your´s.
You can change also the destination folder - but leave it as it is If you do: you have to change it in the converting-video batch-script too.
Code:
REM Please enter the path where your internalstorage or micro-SD is mounted in recovery:
[COLOR="Red"]set extpath=/sdcard[/COLOR]
REM e.g. set "extpath=/external_sd" if your micro-sd is mounted IN RECOVERY at /external_sd
REM (default-path: /sdcard for internal storage)
Mountpoint of micro SD is different on any devices, you can change it to your´s.
Code:
REM Please enter the path where your internalstorage or micro-SD is mounted:
[COLOR="Red"]set extpath=/sdcard[/COLOR]
REM E.g. set "extpath=/extSdCard" if your micro-sd is mounted at /extSdCard
REM (default-path: /sdcard for internal storage)
REM
REM
REM
REM Please enter the name of your destinationfolder on your computer:
[COLOR="Red"]set destpath=tmpandroid[/COLOR]
REM (default-path: tmpandroid)
Mountpoint of micro SD is different on any devices, you can change it to your´s.
You can change also the destination folder - but leave it as it is If you do: You have to change it in the converting-video batch-script too.
Code:
REM Please enter the path where your internalstorage or micro-SD is mounted in recovery
[COLOR="Red"]set extpath=/sdcard[/COLOR]
REM e.g. set "extpath=/external_sd" if your micro-sd is mounted IN RECOVERY at /external_sd
REM (default-path: /sdcard for internal storage)
REM
REM
REM Please enter the name of your png-folder on your computer
REM (same as "destpath" in record_recovery-universal.bat)
[COLOR="Red"]set pngpath=tmp[/COLOR]
REM (default-path:tmp - if you have modified the path do the same here)
Mountpoint of micro SD is different on any devices, you can change it to your´s. If you have changed it in the record_recover-batch-script - you have to do it too.
You can change also the destination folder - but leave it as it is If you have changed it in the record_recovery-batch-script - you have to do it too.
Code:
REM Please enter the name of your png-folder on your computer
REM (same as "destpath" in record_runnning_android-universal.bat)
[COLOR="Red"]set pngpath=tmpandroid[/COLOR]
REM (default-path:tmpandroid - if you have modified the path do the same here)
You can change also the png folder - but leave it as it is If you have changed it in the record_running_android-batch-script - you have to do it too.
Please use Notepad++ if you want to change something in the batch-script.
For watching the .mp4 you can use Media Player Home Cinema.
Click to expand...
Click to collapse
drawbacks of your method :fingers-crossed: :
not all devices are fast enough to process the "capture>pull>remove" loop which you have implemented.
except that, awesomeness quotient is great. you have added support for capturing the screen while android is running in normal mode :victory:
It can be just downloaded and extracted into the folder where you already have the files... releasing it as version 2.0
p.s. Guess its time for me to update the linux version
vineethraj49 said:
drawbacks of your method :fingers-crossed: :
not all devices are fast enough to process the "capture>pull>remove" loop which you have implemented.
Click to expand...
Click to collapse
Maybe i can make 2 batch files (pulling as a second step). Maybe add the pull line into the "mkvideo_mp4_running_android-universal.bat".
I can test it after sleeping :silly:
And you´re right: its not so fast like in recovery (on my Galaxy Tab 2 7.0 P3110)
vineethraj49 said:
except that, awesomeness quotient is great. you have added support for capturing the screen while android is running in normal mode :victory:
Click to expand...
Click to collapse
Thank you Thanks for your great work before my modification - my modification wouldn´t be possible without you :good:
vineethraj49 said:
It can be just downloaded and extracted into the folder where you already have the files... releasing it as version 2.0
p.s. Guess its time for me to update the linux version
Click to expand...
Click to collapse
Do it
Because i´m not running a linux i couldn´t make it (and i´m not that good at linux).
Maybe i can make 2 batch files (pulling as a second step). Maybe add the pull line into the "mkvideo_mp4_running_android-universal.bat".
I can test it after sleeping :silly:
And you´re right: its not so fast like in recovery (on my Galaxy Tab 2 7.0 P3110)
Click to expand...
Click to collapse
Yeah, recovery... too slow
Thank you Thanks for your great work before my modification - my modification wouldn´t be possible without you :good:
Click to expand...
Click to collapse
Thank Kyan He and Whiskey103 too
Do it
Because i´m not running a linux i couldn´t make it (and i´m not that good at linux).
Click to expand...
Click to collapse
https://github.com/vineethraj49/android-shot
If you are interested, you can send in pull requests to https://github.com/vineethraj49/android-shot/tree/windows. PM me if interested to maintain the git,I will add you as a collaborator.
vineethraj49 said:
Yeah, recovery... too slow
Thank Kyan He and Whiskey103 too
https://github.com/vineethraj49/android-shot
If you are interested, you can send in pull requests to https://github.com/vineethraj49/android-shot/tree/windows. PM me if interested to maintain the git,I will add you as a collaborator.
Click to expand...
Click to collapse
sure, big thank @ Kyan He and Whiskey103 too!
i'll release update 2.0.1 later. i'm working on it. PM to you later.
pull won't work on windows. i tryed over vbs but didn't got it work.
Version 2.0.1 (extra batch-files)
Download 2.0.1 from here
Installation:
Download and extract V 1.0 from op.
Extract "universal-bat2.0.1.zip" and copy all *.bat to "android-shot" directory.
Changes:
Code:
[LIST][*]not pulling data from your device (slowed down the recording process) @ record_running_android-universal.bat
[*]pulling before converting (better for recording process) @ mkvideo_mp4_running_android-universal.bat[/LIST]
How-To make a video in recovery:
1. start "record_recovery-universal.bat" (press CTRL + C if you are finished)
2. start "mkvideo_mp4_recovery-universal.bat" and follow the instructions.
How-To make a video in running android:
1. start "record_running_android-universal.bat" (press CTRL + C if you are finished)
2. start "mkvideo_mp4_running_android-universal.bat" and follow the instructions.
You can change the path from sdcard (default) to your micro-SD like before (different devices = different mountpoints) (instructions)
Thanks
@vineethraj49
Kyan He (https://plus.google.com/116857119889961125943) and his wonderful tool "fb2png" (https://code.google.com/p/android-fb2png/)
Whiskey103 (http://forum.xda-developers.com/member.php?u=2632943) and his guide (http://forum.xda-developers.com/showthread.php?p=40260716) on taking screenshot in windows.
Edit 30.07.2013:
Changed Download-Link, still 2.0.1 (some UI changes of the running batch)
time to update thread title I guess!
@Android-Andi, could you post a video for android_running_system for video recording as a sample?
vineethraj49 said:
@Android-Andi, could you post a video for android_running_system for video recording as a sample?
Click to expand...
Click to collapse
Shure,can do it next days,maybe today.
for rooted devices
is there anyby some gesture
Hi everyone sorry for this question but haven't been able to find any info on backing up the stock rom of a device.
It is a Samsung so not sure if fastboot would be an option and yet to install any recovery image (TWRP)
Please advise what would be the best way before installing a custom ROM for backing up the stock roms of the device.
I also want to backup the recovery before adding a customer recovery if possible.
Thanks for any help
Only for demonstration purpose:
Here excerpt of a Windows CMD script I times ago wrote to fully backup a phone by means of ADB
Code:
rem THIS DOESN'T WORK ON MTK-CHIPSET BASED DEVICES!
rem
rem for MTD and EMMC devices, the partition layout and the partition names
rem can be retrieved by reading the /proc/mtd and /proc/emmc files.
set file_to_query=
for /F %%a in ('adb shell "[ -f /proc/mtd ]; echo $?"') do (
set "error=%%a"
if "%error%"=="0" (
set "part_layout=mtd"
set "file_to_query=/proc/%part_layout%"
)
)
if not defined file_to_query (
for /F %%a in ('adb shell "[ -f /proc/emmc ]; echo $?"') do (
set "error=%%a"
if "%error%"=="0" (
set "part_layout=emmc"
set "file_to_query=/proc/%part_layout%"
)
)
)
if not defined file_to_query ( goto :failed )
for /F "skip=1" "tokens=1,4 delims= " %%a in ('adb shell "cat %file_to_query%"') do (
rem get dev-name and corresponding part-name
set "dev_name=%%a" & set "part_name=%%b"
if not "?%dev_name%"=="?" (
rem remove colon
set "dev_name=%dev_name::=%"
rem remove double quotes
set "part_name=%part_name:"=%"
rem write out dump to pc
adb exec-out "dd if=/dev/%part_layout%/%dev_name% bs=4096" > "C:\%part_name%.img"
timeout /t 2 /nobreak >nul
)
)
:failed
From what I have read phone needs to be rooted to complete the backup via adb
How do i make this tool by: Ryuinferno Windows Sign Em v2-0
[TOOL][WINDOWS]Sign-em! v2.0 ->Batch sign zip files | No signature verification error
[TOOL][WINDOWS]Sign-em! v2.0 ->Batch sign zip files | No signature verification error Sign-em! v2.0 Hi all! As we know, making zip files is a must no matter when we want to flash a new ROM, theme, mods and so on...but at times we need to sign...
forum.xda-developers.com
Work with the new apksigner.jar file which on windows has to be used through the apksigner bat file?
The batch script in the tool from Ryuinferno is this:
@Echo off
COLOR 70
title "Sign-em! 2.0"
ECHO.
ECHO Sign-em! v2.0 by Ryuinferno @ XDA 2013
ECHO.
ECHO This script signs multiple zip files automatically...
ECHO.
ECHO **REMINDER!!! Do not leave spaces when you name your zip files...**
ECHO.
FOR %%A in (.\Input\*.zip) do (
ECHO Signing - %%~nA.zip
java -jar .\Tools\signapk.jar -w .\Tools\testkey.x509.pem .\Tools\testkey.pk8 %%A .\Output\%%~nA-signed.zip
)
FOR %%A in (.\Output\*.zip) do (
ECHO Calculating md5 checksum
.\Tools\md5sums.exe -u %%A >> ./Output/md5.txt
)
ECHO.
ECHO Files signed successfully if no errors above...
ECHO.
ECHO Hope you enjoyed my work...
ECHO Ryuinferno @ XDA 2013
ECHO.
pause
peter1miller2 said:
How do i make this tool by: Ryuinferno Windows Sign Em v2-0
[TOOL][WINDOWS]Sign-em! v2.0 ->Batch sign zip files | No signature verification error
[TOOL][WINDOWS]Sign-em! v2.0 ->Batch sign zip files | No signature verification error Sign-em! v2.0 Hi all! As we know, making zip files is a must no matter when we want to flash a new ROM, theme, mods and so on...but at times we need to sign...
forum.xda-developers.com
Work with the new apksigner.jar file which on windows has to be used through the apksigner bat file?
Click to expand...
Click to collapse
To execute a .JAR-file on Windows, you need to install Java on your system. Go to Java Download Page and install it.
I am not asking how to execute a JAR file. I am asking how to make the Apk Signer sign all files in a folder like this tool does with the older zip signer.
If you do not have OpenSSL installed on Windows machine, download and install it. You need OpenSSL to create a private key and a corresponding public key, which act as your digital signature.
On elevated Windows command prompt enter the following commands to generate a new private key and a corresponding public key for yourself:
Code:
openssl genrsa -out key.pem 1024
openssl req -new -key key.pem -out request.pem
openssl x509 -req -days 9999 -in request.pem -signkey key.pem -out certificate.pem
openssl pkcs8 -topk8 -outform DER -in key.pem -inform PEM -out key.pk8 -nocrypt
In Windows you create a folder named ZipSignerTool with 4 subfolders named InFiles & OutFiles & Tools & Keys.
In subfolder InFiles you place all the .ZIP-files what should get signed.
In subfolder Tools you place the Java executable named signapk.jar.
In subfolder Keys you place the 2 files you generated by means of OpenSSL as shown above.
You create a Windows batch-file in folder ZipSignerTool named ZipSigner.bat ( or whatever ) that does the job:
Code:
@echo off & setlocal
pushd "%~dp0"
set "InFiles=%CD%\Infiles"
set "OutFiles=%CD%\OutFiles"
set "Signer=%CD%\Tools\signapk.jar"
set "Keys=%CD%\Keys"
for /F %%a in ('dir %InFiles%\*.zip /B') do (
set "ZIP=%%a"
if NOT "?%ZIP%"=="?" (
java -jar %Signer% %Keys%\certificate.pem %Keys%\key.pk8 %ZIP% %OutFiles%\signed-%ZIP%
)
)
popd
endlocal & @echo on & exit
jwoegerbauer said:
If you do not have OpenSSL installed on Windows machine, download and install it. You need OpenSSL to create a private key and a corresponding public key, which act as your digital signature.
On elevated Windows command prompt enter the following commands to generate a new private key and a corresponding public key for yourself:
Code:
openssl genrsa -out key.pem 1024
openssl req -new -key key.pem -out request.pem
openssl x509 -req -days 9999 -in request.pem -signkey key.pem -out certificate.pem
openssl pkcs8 -topk8 -outform DER -in key.pem -inform PEM -out key.pk8 -nocrypt
In Windows you create a folder named ZipSignerTool with 4 subfolders named InFiles & OutFiles & Tools & Keys.
In subfolder InFiles you place all the .ZIP-files what should get signed.
In subfolder Tools you place the Java executable named signapk.jar.
In subfolder Keys you place the 2 files you generated by means of OpenSSL as shown above.
You create a Windows batch-file in folder ZipSignerTool named ZipSigner.bat ( or whatever ) that does the job:
Code:
@echo off & setlocal
pushd "%~dp0"
set "InFiles=%CD%\Infiles"
set "OutFiles=%CD%\OutFiles"
set "Signer=%CD%\Tools\signapk.jar"
set "Keys=%CD%\Keys"
for /F %%a in ('dir %InFiles%\*.zip /B') do (
set "ZIP=%%a"
if NOT "?%ZIP%"=="?" (
java -jar %Signer% %Keys%\certificate.pem %Keys%\key.pk8 %ZIP% %OutFiles%\signed-%ZIP%
)
)
popd
endlocal & @echo on & exit
Click to expand...
Click to collapse
Thank you very much for your answer. I am sure it would work. Thought since i completely failed to explain the real problem i have. it is currently not working for me. I hope i explained the problem better in my new post here: https://forum.xda-developers.com/t/how-can-i-batch-sign-zip-files-on-windows.4361871/ and thank you again wery much for the answer.
I asked this previously.
But i did not specify the problem correctly When i unpack the:
build-tools_r30.0.1-windows.zip to the C drive i get this:
C:\android-11\
If i try to use the ApkSigner.JAR in the:
C:\android-11\lib\
Folder Directly through those two commands:
cd C:\Program Files\AdoptOpenJDK\jre-16.0.1.9-hotspot\bin\
Followed by:
java.exe C:\android-11\lib\apksigner.jar sign --key C:\keys\mykey.pk8 --cert C:\certificates\mycert.pem --min-sdk-version 20 C:\files\MyZipFile.zip
I get this:
Error: Could not find or load main class C:\android-11\lib\apksigner.jar
Caused by: java.lang.ClassNotFoundException: C:\android-11\lib\apksigner.jar
If i use the ApkSigner.JAR INDIRECTLY Through the ApkSigner.BAT File in the:
C:\android-11\
Folder Through those two commands:
cd C:\android-11\
Followed by:
apksigner.bat sign --key C:\keys\mykey.pk8 --cert C:\certificates\mycert.pem --min-sdk-version 20 C:\files\MyZipFile.zip
Than it works But the apksigner.BAT File does not work with the batch signer i mentioned in this post: https://forum.xda-developers.com/t/how-to-batch-sign-zip-files.4258547/
Which is why Batch signing is not working for me with the current apksigner.JAR File.
Since because of this
Error:
Could not find or load main class C:\android-11\lib\apksigner.jar
Caused by: java.lang.ClassNotFoundException: C:\android-11\lib\apksigner.jar
I cannot use it directly.
The script from the apksigner.BAT File is this:
@Echo off
REM Copyright (C) 2016 The Android Open Source Project
REM
REM Licensed under the Apache License, Version 2.0 (the "License");
REM you may not use this file except in compliance with the License.
REM You may obtain a copy of the License at
REM
REM http://www.apache.org/licenses/LICENSE-2.0
REM
REM Unless required by applicable law or agreed to in writing, software
REM distributed under the License is distributed on an "AS IS" BASIS,
REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
REM See the License for the specific language governing permissions and
REM limitations under the License.
REM don't modify the caller's environment
setlocal
REM Locate apksigner.jar in the directory where apksigner.bat was found and start it.
REM Set up prog to be the path of this script, including following symlinks,
REM and set up progdir to be the fully-qualified pathname of its directory.
set prog=%~f0
@Rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if "%ERRORLEVEL%" == "0" goto init
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
exit /b 1
:findJavaFromJavaHome
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto init
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
exit /b 1
:init
set jarfile=apksigner.jar
set "frameworkdir=%~dp0"
rem frameworkdir must not end with a dir sep.
set "frameworkdir=%frameworkdir:~0,-1%"
if exist "%frameworkdir%\%jarfile%" goto JarFileOk
set "frameworkdir=%~dp0lib"
if exist "%frameworkdir%\%jarfile%" goto JarFileOk
set "frameworkdir=%~dp0..\framework"
:JarFileOk
set "jarpath=%frameworkdir%\%jarfile%"
set javaOpts=
set args=
REM By default, give apksigner a max heap size of 1 gig and a stack size of 1meg.
rem This can be overridden by using "-JXmx..." and "-JXss..." options below.
set defaultXmx=-Xmx1024M
set defaultXss=-Xss1m
REM Capture all arguments that are not -J options.
REM Note that when reading the input arguments with %1, the cmd.exe
REM automagically converts --name=value arguments into 2 arguments "--name"
REM followed by "value". apksigner has been changed to know how to deal with that.
set params=
:firstArg
if [%1]==[] goto endArgs
set "a=%~1"
if [%defaultXmx%]==[] goto notXmx
if "%a:~0,5%" NEQ "-JXmx" goto notXmx
set defaultXmx=
:notXmx
if [%defaultXss%]==[] goto notXss
if "%a:~0,5%" NEQ "-JXss" goto notXss
set defaultXss=
:notXss
if "%a:~0,2%" NEQ "-J" goto notJ
set javaOpts=%javaOpts% -%a:~2%
shift /1
goto firstArg
:notJ
set params=%params% %1
shift /1
goto firstArg
:endArgs
set javaOpts=%javaOpts% %defaultXmx% %defaultXss%
call "%java_exe%" %javaOpts% -jar "%jarpath%" %params%
The script From the SignEm v2.0 Tool: From this Post:
https://forum.xda-developers.com/t/...iles-no-signature-verification-error.1966007/
By @Ryuinferno is this
@Ryuinferno said:
@Echo off
COLOR 70
title "Sign-em! 2.0"
ECHO.
ECHO Sign-em! v2.0 by Ryuinferno @ XDA 2013
ECHO.
ECHO This script signs multiple zip files automatically...
ECHO.
ECHO **REMINDER!!! Do not leave spaces when you name your zip files...**
ECHO.
FOR %%A in (.\Input\*.zip) do (
ECHO Signing - %%~nA.zip
java -jar .\Tools\signapk.jar -w .\Tools\testkey.x509.pem .\Tools\testkey.pk8 %%A .\Output\%%~nA-signed.zip
)
FOR %%A in (.\Output\*.zip) do (
ECHO Calculating md5 checksum
.\Tools\md5sums.exe -u %%A >> ./Output/md5.txt
)
ECHO.
ECHO Files signed successfully if no errors above...
ECHO.
ECHO Hope you enjoyed my work...
ECHO Ryuinferno @ XDA 2013
ECHO.
pause
Click to expand...
Click to collapse
And the Script created by: @jwoegerbauer As this answer:
https://forum.xda-developers.com/t/how-to-batch-sign-zip-files.4258547/post-84798393
To my earlier post is here:
@jwoegerbauer said:
@Echo off & setlocal
pushd "%~dp0"
set "InFiles=%CD%\Infiles"
set "OutFiles=%CD%\OutFiles"
set "Signer=%CD%\Tools\signapk.jar"
set "Keys=%CD%\Keys"
for /F %%a in ('dir %InFiles%\*.zip /B') do (
set "ZIP=%%a"
if NOT "?%ZIP%"=="?" (
java -jar %Signer% %Keys%\certificate.pem %Keys%\key.pk8 %ZIP% %OutFiles%\signed-%ZIP%
)
)
popd
endlocal & @ECHO on & exit
Click to expand...
Click to collapse
And I wery much Hope someone can help me with this problem.
Are you sure that apksigner.jar is in the folder of 'C:\android-11\lib'?
James_Watson said:
Are you sure that apksigner.jar is in the folder of 'C:\android-11\lib'?
Click to expand...
Click to collapse
Yes i am sure about that.