lmj0011 / save-on-device Goto Github PK
View Code? Open in Web Editor NEWAndroid app that allows you to save a file shared from another app to your device.
Android app that allows you to save a file shared from another app to your device.
After selecting multiple files and choosing a directory to save the file to, a prompt to "Allow Save to access files in [selected directory]" is asked every time.
Attempts were made using the methods described here without success.
area of interest: https://github.com/lmj0011/save-on-device/blob/v0.4.0/app/src/main/java/name/lmj001/saveondevice/MainActivity.kt#LL73C9-L111C9
FATAL EXCEPTION: main
Process: name.lmj001.savetodevice, PID: 14239
java.lang.RuntimeException: Unable to start activity ComponentInfo{name.lmj001.savetodevice/name.lmj001.saveondevice.MainActivity}: java.lang.NullPointerException: null cannot be cast to non-null type android.net.Uri
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:4035)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:4201)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:103)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2438)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:226)
at android.os.Looper.loop(Looper.java:313)
at android.app.ActivityThread.main(ActivityThread.java:8663)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:567)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1135)
Caused by: java.lang.NullPointerException: null cannot be cast to non-null type android.net.Uri
at java.util.Objects.requireNonNull(Objects.java:245)
at name.lmj001.saveondevice.MainActivity.onCreate(MainActivity.kt:52)
at android.app.Activity.performCreate(Activity.java:8290)
at android.app.Activity.performCreate(Activity.java:8270)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1329)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:4009)
... 12 more
Thanks for this really useful app! But I encountered the following issue:
If I share some pain text and try to save it with this app into a file the app crashes with this stack trace:
FATAL EXCEPTION: main
Process: name.lmj001.savetodevice, PID: 8539
java.lang.RuntimeException: Unable to start activity ComponentInfo{name.lmj001.savetodevice/name.lmj001.saveondevice.MainActivity}: java.lang.NullPointerException: null cannot be cast to non-null type android.net.Uri
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3645)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3782)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:101)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2307)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:201)
at android.os.Looper.loop(Looper.java:288)
at android.app.ActivityThread.main(ActivityThread.java:7872)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:936)
Caused by: java.lang.NullPointerException: null cannot be cast to non-null type android.net.Uri
at name.lmj001.saveondevice.MainActivity.onCreate(MainActivity.kt:52)
at android.app.Activity.performCreate(Activity.java:8305)
at android.app.Activity.performCreate(Activity.java:8284)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1417)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3626)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3782)
at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:101)
at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2307)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:201)
at android.os.Looper.loop(Looper.java:288)
at android.app.ActivityThread.main(ActivityThread.java:7872)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:548)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:936)
It seems the is no EXTRA_STREAM field in this case.
I tried using this to save a photo from the vector camera app in f-droid. The photo is actually a .jpg but save on device tries to save it as a png and the file comes up 0 bytes.
Title. Would be great if it's possible
This seems like a real useful little tool – a pity it's only installable via Google's walled garden. Would you mind making it available for users without access to the Playstore? Like, tagging releases and attaching the APK there, or have your app built and listed by F-Droid?
I've made a fdroid build recipe for this Save on Device app since I find it really useful: https://gitlab.com/fdroid/fdroiddata/-/merge_requests/10077
Do you agree that we list it on f-droid.org?
please, is it possible to add min_sdk 21 (android 5.0) support,
or at least min_sdk 22 (android 5.1) it not possible first.
great thanks in advance.
Hi, I love the premise of your app! Using the regular "Downloads" app on my phone requires me to unblock System in my firewall, so I've had to make a workaround in Termux. It would be really nice to have a trustworthy FOSS app to save files. Unfortunately I'm still running Android 7.0. Is there any chance of getting this to work on an older version than 9? I would be really grateful!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.