CLI Screenshot app [Notify-OSD support] - Ubuntu Touch Apps and Games

This will take a screenshot and save it to /home/phablet/Pictures
When exectued it'll ask how many seconds you want to wait. you choose x amount of seconds, push enter and navigate to where you want the screenshot to be taken.
it'll notify you when the screenshot is finished via the native notification service
Code:
#!/bin/bash
echo "ScreenShot App for Ubuntu Touch"
echo ""
echo ""
echo "How many seconds do you want to wait before the screenshot is captured? "
read SEC
sleep $SEC
NOW=$(date)
SCREEN="screenshot-$NOW.png"
/system/bin/screencap -p /home/phablet/Pictures/"$SCREEN"
notify-send "Screenshot Captured" "Saved in /home/phablet/Pictures"
INSTRUCTIONS!!!
save the file as screenshot
push to /usr/bin/
chmod 755 /usr/bin/screenshot
run screenshot
enjoy.

I'm going to implement this into QML if I can find a way to pass shell commands or maybe just run the shell script and then render the image on the app canvas.
Sent from my Galaxy Nexus using XDA Premium 4 mobile app

blmvxer said:
I'm going to implement this into QML if I can find a way to pass shell commands or maybe just run the shell script and then render the image on the app canvas.
Sent from my Galaxy Nexus using XDA Premium 4 mobile app
Click to expand...
Click to collapse
You can run shell commands using a C++ plugin but it won't work properly with click packages. You'll need to use the unconfined template in your apparmor *.json file and apps which are run without confinement won't be included in the app store.
However, I guess that they will add a way to take screenshots to the OS itself later.

how to install notify-send ?

Getting back on this app soon. Hopefully I can do some binary work. I've been dabbling with C and C++.
Sent from my LGLS990 using XDA Free mobile app

Iust wanted to inform you that this feature will soon be included into the system images, so you may want to save the time for packaging up your cli tool.
https://bugs.launchpad.net/ubuntu/+source/unity8/+bug/1369644
Sent from my awesome Ubuntu Touch device using the Forum Browser app

Related

[working]Google Movies

I was able to rent, and watch a movie on my rooted NC. I followed this post http://forum.xda-developers.com/showpost.php?p=15620050&postcount=175
instead of bin I typed in xbin.
Sent from my Droid
So the takeaway from this is that Google Movies is looking for SU by name and renaming it MU (or just about anything else) gets around the "root" check.
Cool. Does this allow the Movies section in Google Market to show up?
From what I've read, yes it is looking for SU by name. You're root apps no longer work while in MU, just an fyi.
I don't have the new market on my NC any longer. I reverted to the older version. I rented the movie from my DROID with the new market. Opened the google videos app on my NC, linked to my gmail, and the movie was there ready for viewing.
Sent from my NOOKcolor using the xda app
It would be great if someone could make an app to toggle this.
Sent from my NookColor using XDA Premium App
Calla969 said:
It would be great if someone could make an app to toggle this.
Sent from my NookColor using XDA Premium App
Click to expand...
Click to collapse
You read my mind. That would be sweet!
Google Movies Root Workaround Script
Calla969 said:
It would be great if someone could make an app to toggle this.
Sent from my NookColor using XDA Premium App
Click to expand...
Click to collapse
I know it isn't an App (I'll work on that later) but here is a script you can run from a Terminal Emulator.
Just download the script to the root of your SDcard and then run this in Terminal:
Code:
sh /sdcard/googlevideo.sh
It'll Autodetect where SU is and whether you're running the script as Root or not. If you aren't Root it'll inform you whether you need to run "su" or "mu" to get Root. Once Run as Root it'll automatically rename SU as needed.
Download the Script here: http://db.tt/nNy1jCy
I started a topic for the script. If you have any questions ask there.
http://forum.xda-developers.com/showthread.php?t=1223630
Google Movies Workaround Script
Found this app, where the root check is disabled.
http://forum.sdx-developers.com/ind...um.sdx-developers.com/index.php?topic=16930.0

[Q] Any app to access root folders from PC?

Is there any app that lets the user download, upload, change and browse folders (over the network. Not wired) from the PC? Not just the storage, I'm talking all folders including /system/ and /data (so if an app exists it must have superuser privilege).
Looks like not. Time to develop one! Will be free if i finish it!
ADB over wifi, but you obviously need to be familiar with terminal.
QuickSSHd or SSHDroid are what I used before
Droid explorer
Sent from my SAMSUNG-SGH-I717 using xda premium

How To - Load full desktop websites permanently in Chrome for Android Mobile

Hey guys, I wrote an article over on our site that shows a quick walkthrough on how to display full desktop websites permanently on Chrome for Android Mobile so that you don't have to visit the mobile site, then hit "request desktop site" button any more. Considering Chrome is an awesome browser with full sync, and works very well on Jelly Bean, this might be of use to all of you. I know I was sick of having to constantly click the button.
Article: How To – Permanently Have Desktop Mode on Chrome Mobile for Android
Rooted device Instructions:
Copy the chrome-command-line.txt file attached to the post, then paste it into /data/local/ making sure to set the permissions to 755 and to remove the '.txt' file extension.
Flashable .zip, for the lazy:
You should know how to use this by now. Grab the attached ChromeDE.zip provided by XDA user djmcnz and flash away! (Thanks!) You can also drop him a thanks by visiting a post of his later in this thread.
ADB Instructions (for non-rooted devices):
Place the chrome-command-line.txt file in the root directory of your PC and rename it to 'chrome-command-line', then make sure your device is connected to your computer. When connected, issue this command:
Code:
adb push /chrome-command-line /data/local/chrome-command-line
You can also set the path on your computer where the file is located by replacing the first '/chrome-command-line' with the file location.
Cheers! Hopefully we'll see a better implementation of this in the upcoming 4.2 release.
Very useful. Instructions were clear and precise, Nice one!
thank you very well apreciated is there any chance you can write 1 on how to make it more stable?
b3ava said:
thank you very well apreciated is there any chance you can write 1 on how to make it more stable?
Click to expand...
Click to collapse
Thanks guys, glad I could help. Wish I knew how to make it more stable! It seems that it runs much better on Jelly Bean, but us ICS users are still stuck with it being really slow and buggy
Sent from my GT-N7000 using XDA Premium HD app
I am stuck trying to figure out what "set permissions to 755" means...
it seems in the video you just tick different boxes, how does that relate to 755??
Sent from my Transformer Prime TF201 using Tapatalk 2
bunnybash said:
I am stuck trying to figure out what "set permissions to 755" means...
it seems in the video you just tick different boxes, how does that relate to 755??
Sent from my Transformer Prime TF201 using Tapatalk 2
Click to expand...
Click to collapse
I'm using solid explorer off of the market (a free file manager) which allows you to set the permissions of a file. In solid explorer, they are set by ticking the correct boxes, whereas in other applications they are typed in by number..
Sent from my GT-N7000 using XDA Premium HD app
Hey thanks for this....huge chrome pet peeve of mine...
Can you write a command for FULL screen!!
When i click the download command file (on Nexus)it just opens to a large field with text...nothing downloads.
Suggestion?
thanks
rockky said:
Hey thanks for this....huge chrome pet peeve of mine...
Can you write a command for FULL screen!!
When i click the download command file (on Nexus)it just opens to a large field with text...nothing downloads.
Suggestion?
thanks
Click to expand...
Click to collapse
You can just copy the text and paste it into the correct location in a file called "chrome-command-line"
Sent from my GT-N7000 using XDA Premium HD app
Thanks very much...got it.
Hey, (cough , hate to push a good thing) do you think you could produce a similar command to enable full screen on chrome mobile?!!
QUOTE=omac_ranger;30213316]You can just copy the text and paste it into the correct location in a file called "chrome-command-line"
Sent from my GT-N7000 using XDA Premium HD app[/QUOTE]
rockky said:
Thanks very much...got it.
Hey, (cough , hate to push a good thing) do you think you could produce a similar command to enable full screen on chrome mobile?!!
QUOTE=omac_ranger;30213316]You can just copy the text and paste it into the correct location in a file called "chrome-command-line"
Sent from my GT-N7000 using XDA Premium HD app
Click to expand...
Click to collapse
Don't think it works that way mate. That one was built into Chrome, just enabled by the file.
Sent from my GT-N7000 using XDA Premium HD app
great guide. thanks for this. having to keep requesting desktop had become a bug bear for me
zionwolf said:
great guide. thanks for this. having to keep requesting desktop had become a bug bear for me
Click to expand...
Click to collapse
Exactly! Glad I could help!
Sent from my Transformer Prime TF201 using XDA Premium HD app
Good tip but it can be improved.
You don't need root to write to /data/local/ so in theory this trick will work for everyone, might pay to update the article.
djmcnz said:
Good tip but it can be improved.
You don't need root to write to /data/local/ so in theory this trick will work for everyone, might pay to update the article.
Click to expand...
Click to collapse
No? When testing with a Nexus 7 unrooted you cannot navigate to Data/local through Solid Explorer. Naturally I thought it had to be rooted. If you have had success with a different file manager (or pushed it through ADB) then letting me know what worked would be great.
omac_ranger said:
No? When testing with a Nexus 7 unrooted you cannot navigate to Data/local through Solid Explorer. Naturally I thought it had to be rooted. If you have had success with a different file manager (or pushed it through ADB) then letting me know what worked would be great.
Click to expand...
Click to collapse
You'll be able to get to it in a terminal window or adb - not sure what's up with Solid, equally an update.zip will work without root.
/data/local/ is r/w for the local user and shell.
try - echo test > /data/local/test.txt on a non-rooted device, it'll work.
Actually, now that think about it more - Solid probably can't list the contents of / (root) so you can't navigate to sub directories. Can you type a path into Solid? That should work.
djmcnz said:
You'll be able to get to it in a terminal window or adb - not sure what's up with Solid, equally an update.zip will work without root.
/data/local/ is r/w for the local user and shell.
try - echo test > /data/local/test.txt on a non-rooted device, it'll work.
Actually, now that think about it more - Solid probably can't list the contents of / (root) so you can't navigate to sub directories. Can you type a path into Solid? That should work.
Click to expand...
Click to collapse
I'll definitely test that out and put a guide for newbies on there. Solid displays the root directory, but will not allow you to navigate to a folder inside of it. I was thinking about ease of access for the user, and assumed they wouldn't want to go the adb route. My bad, but thank you for the heads up.
Sent from my GT-N7000 using XDA Premium HD app
omac_ranger said:
I'll definitely test that out and put a guide for newbies on there. Solid displays the root directory, but will not allow you to navigate to a folder inside of it. I was thinking about ease of access for the user, and assumed they wouldn't want to go the adb route. My bad, but thank you for the heads up.
Sent from my GT-N7000 using XDA Premium HD app
Click to expand...
Click to collapse
If you want it as easy as possible you could provide an update.zip for those with a custom recovery - that's going to be the simplest way. If you want to do that and need some help let me know.
does what is says on the tin
well spotted and thanks for posting
djmcnz said:
If you want it as easy as possible you could provide an update.zip for those with a custom recovery - that's going to be the simplest way. If you want to do that and need some help let me know.
Click to expand...
Click to collapse
Yeah I would love some help with that. I've never tried to compile my own before. I have a few tools bookmarked, but haven't gone through with testing them too thoroughly.
tony_man said:
well spotted and thanks for posting
Click to expand...
Click to collapse
No problem. Mind dropping a thanks? Waiting at 99 is a huge pain the arse.
omac_ranger said:
Yeah I would love some help with that. I've never tried to compile my own before. I have a few tools bookmarked, but haven't gone through with testing them too thoroughly.
Click to expand...
Click to collapse
No worries, I can whip one up in a few minutes when I get home.
In the meantime you can have a look at some here: http://djmcnz.batteryboss.org/GNexus/mods/StockLauncher/v4/
If you want to have a play and look at the script. It will need to be different for you of course, least of all because we'll be mounting /data instead.
I'll send you a PM later on once I'm home (I'm in Europe/CET).
PS - 100

Busybox?

Do we need to have Busybox installed on our phones? Always had it on my other rooted and unlocked devices.
Sent from my LG-E970 using xda app-developers app
Only if you're doing anything with the terminal emulator, I believe.
There are a handful of root-aware apps that use busybox for various functions. All the ones I've seen check for it and will try to install a copy if it's missing (if they don't just include it). I personally like having it around because I like to do things in the shell and it brings a lot of the comfortable unix commands. But it's not necessary for operation of the phone.
For what it's worth, I've been using JRummy's BusyBox Installer with good results.
Sent from my LG-E970 using xda premium

Working on an Ubuntu Touch WebApp

Nothing special. Just a WebApp for my store.
But I'm having trouble with something simple.
I'm trying to make a simple changelog using qml. The change log will be separate from the main application and called onto the already established canvas.
I know how to call the qml file I just can't make a simple read only change log in QML.
Sent from my Galaxy Nexus using XDA Premium 4 mobile app
How did you create the webapp? Using QML or the webapp packaging guide?
If you used QML, have a look at the PageStack component and push a new Page component. Inside you can have a Flickable containing a Label with your changelog code. You should even be able to use some html formatting for it. Or go with html completely.
I did use pagestack. Not what I want exactly. But now that I am getting comfortable with QML things are getting easier.
And I used webview and with JS core to display the page and adjust it to fit all screen sizes.
Sent from my Galaxy Nexus using XDA Premium 4 mobile app

Categories

Resources