BlackBerryForums.com : Your Number One BlackBerry Community  
   

»Sponsored Links



Reply
 
LinkBack Thread Tools
  (#1 (permalink)) Old
rivviepop Offline
BlackBerry Extraordinaire
 
rivviepop's Avatar
 
Posts: 2,139
Join Date: Dec 2006
Location: san francisco
Model: 8320
PIN: n/a
Carrier: t-mobile
Default Script: Download OTA app to install from SD card - 04-18-2008, 12:01 PM

A utilitarian script to download a large OTA app and all it's COD/JAR/JAD files - such as the Mobipocket Reader - to your workstation so you can install it on your device using your SD card instead; handy if the app is really large, have problems with your device data connection, or pay a lot for the data usage on your device. Usage is simple and easy:

Download Usage

1) save the below code as 'getapp.sh'
2) edit getapp.sh to put in the proper URL and JAD file (Mobipocket eReader used as an example)
3) comment/uncomment the use of wget or curl as needed (depends on what you have installed, I like curl)
4) make a new directory and run the script in that directory

Example:
Code:
cd ~
vi getapp.sh (edit/save/exit)
mkdir mpocket
cd mpocket
sh ../getapp.sh

Install Usage

1) copy the folder "mpocket" to your SD card, it should contain all the random COD, JAD and JAR files
2) from your device launch the Media applet
3) Menu key -> Explore -> Media Card -> mpocket folder
4) click on the JAD file to start the install (i.e. mobireader.jad)


getapp.sh
Code:
#!/bin/sh
#
# retrieve an OTA app locally, copy to SD card and install
# from there instead (for large OTA apps)

URL=http://www.mobipocket.com/mobile/downloadsoft/download/mobile4.2.0/
JAD=mobireader.jad

# curl or wget may be used, comment/uncomment as needed
#CMD="wget --quiet"
CMD="curl -s -O"

echo "Retrieving: ${URL}${JAD}"
${CMD} "${URL}${JAD}"

echo "Converting ${JAD}"
dos2unix "${JAD}"

CODS=`cat ${JAD} | grep -i url | cut -f2 -d ' '`
for ii in ${CODS}; do
  echo "Retrieving: ${URL}${ii}"
  ${CMD} "${URL}${ii}"
done

exit 0

# rivviepop at blackberryforums.com
# licensed under the GPLv2
getapp.sh: download OTA app to install from SD card « rivviepop phantom :: knowledge in passing

Last edited by rivviepop : 09-03-2008 at 05:50 PM. Reason: add blog link (go me!)
   
Reply With Quote
Sponsored Links
Please Login or Register to Remove these Advertisements!

  (#2 (permalink)) Old
ma077146 Offline
Talking BlackBerry Encyclopedia
 
ma077146's Avatar
 
Posts: 226
Join Date: Feb 2007
Location: Lexington, SC
Model: 8830
PIN: 3019F3E6
Carrier: Sprint
Default 04-18-2008, 12:32 PM

Very useful, thanks for posting this.


http://ezreregister.com

Like Coupons and Free Shipping?
http://thediscountdude.com
   
Reply With Quote
  (#3 (permalink)) Old
rivviepop Offline
BlackBerry Extraordinaire
 
rivviepop's Avatar
 
Posts: 2,139
Join Date: Dec 2006
Location: san francisco
Model: 8320
PIN: n/a
Carrier: t-mobile
Default 04-18-2008, 12:53 PM

My pleasure - I needed it to download a large (> 1meg) OTA app myself this morning to test for a developer, so as they say - necessity is the mother of invention.
   
Reply With Quote
  (#4 (permalink)) Old
John Clark Offline
BBF Nutjob Mod
 
John Clark's Avatar
 
Posts: 30,509
Join Date: Jun 2005
Model: 8320
OS: 4.5.0.xx
PIN: >Options >Status
Carrier: TMobile
Default 04-18-2008, 06:20 PM

Stuck thread.
   
Reply With Quote
  (#5 (permalink)) Old
rivviepop Offline
BlackBerry Extraordinaire
 
rivviepop's Avatar
 
Posts: 2,139
Join Date: Dec 2006
Location: san francisco
Model: 8320
PIN: n/a
Carrier: t-mobile
Default 04-18-2008, 10:48 PM

Quote:
Originally Posted by John Clark View Post
Stuck thread.
gracias!
   
Reply With Quote
  (#6 (permalink)) Old
rexxxlo Offline
Knows Where the Search Button Is
 
Posts: 17
Join Date: Jul 2008
Model: 8330
PIN: N/A
Carrier: verizon
Default 07-08-2008, 10:43 PM

i love the way inux works i use ubuntu on my deskop and asus eee but when i get in to these codes i get worried

is there a list of what most of this means somewhere?
   
Reply With Quote
  (#7 (permalink)) Old
rivviepop Offline
BlackBerry Extraordinaire
 
rivviepop's Avatar
 
Posts: 2,139
Join Date: Dec 2006
Location: san francisco
Model: 8320
PIN: n/a
Carrier: t-mobile
Default 07-08-2008, 10:50 PM

Quote:
Originally Posted by rexxxlo View Post
i love the way inux works i use ubuntu on my deskop and asus eee but when i get in to these codes i get worried

is there a list of what most of this means somewhere?
Well there's not a 'list' per se, as it's an entire language called Bourne Shell. You can read a beginner and advanced guide at these links:

http://tldp.org/LDP/Bash-Beginners-G...tml/index.html
http://tldp.org/LDP/abs/html/index.html

Other great resources:

http://wooledge.org:8000/BashFAQ?act...direct=BashFaq
Heiner's SHELLdorado
Bash Reference Manual
All about Linux: Bash Shell Shortcuts
   
Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On






Copyright © 2004-2008 BlackBerryNews.com, BlackBerryFAQ.com, BlackBerryForums.com.
The names RIM © and BlackBerry © are registered Trademarks of Research In Motion Limited.
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.0.1