Open With Ardunio, File Open Fails

Bug #998952 reported by arky
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
arduino (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

Opening .ino files with Arduino results in IDE opening an empty sketch.

Trying to opening a file on command line has similar effect.

$ arduino ~/sketchbook/example.ino

---arky
Ubuntu Bug Squad volunteer triager
http://wiki.ubuntu.com/BugSquad

ProblemType: Bug
DistroRelease: Ubuntu 12.04
Package: arduino 1:1.0+dfsg-9
ProcVersionSignature: Ubuntu 3.2.0-24.37-generic 3.2.14
Uname: Linux 3.2.0-24-generic i686
ApportVersion: 2.0.1-0ubuntu7
Architecture: i386
Date: Mon May 14 09:23:39 2012
InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release i386 (20110427.1)
PackageArchitecture: all
ProcEnviron:
 LANGUAGE=en_US:en
 TERM=xterm
 PATH=(custom, user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: arduino
UpgradeStatus: Upgraded to precise on 2012-05-06 (7 days ago)

Revision history for this message
arky (arky) wrote :
Revision history for this message
Scott Howard (showard314) wrote : Re: [Bug 998952] [NEW] Open With Ardunio, File Open Fails

Thanks - I don't think that arduino is capable of taking command line
arguments (am I wrong?)
We should probably not allow nautilus to "open with" arduino.

If I open a .ino in arduino IDE, it opens fine - it's just the "open
with" within nautilus

Revision history for this message
kaedenn (kaedenn) wrote : Re: [Developers] [Bug 998952] [NEW] Open With Ardunio, File Open Fails

Scott,

Fixed this manually a while back. Haven't submitted the patch to
Arduino, since the problem is trivial:

In your arduino shell script that runs the Java client (find it with
`which arduino`), make the following replacement:

- java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel
processing.app.Base
+ java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel
processing.app.Base "$@"

This fixes the issue and allows .ino sketches to be opened with
Arduino's Processing.

Peter

On Sun, May 13, 2012 at 7:52 PM, Scott Howard <email address hidden> wrote:
> Thanks - I don't think that arduino is capable of taking command line
> arguments (am I wrong?)
> We should probably not allow nautilus to "open with" arduino.
>
> If I open a .ino in arduino IDE, it opens fine - it's just the "open
> with" within nautilus
>
> --
> You received this bug notification because you are a member of Arduino
> on Ubuntu Packagers, which is subscribed to arduino in Ubuntu.
> https://bugs.launchpad.net/bugs/998952
>
> Title:
>  Open With Ardunio, File Open Fails
>
> Status in “arduino” package in Ubuntu:
>  New
>
> Bug description:
>  Opening .ino files with Arduino results in IDE opening an empty
>  sketch.
>
>  Trying to opening a file on command line has similar effect.
>
>  $ arduino ~/sketchbook/example.ino
>
>
>  ---arky
>  Ubuntu Bug Squad volunteer triager
>  http://wiki.ubuntu.com/BugSquad
>
>  ProblemType: Bug
>  DistroRelease: Ubuntu 12.04
>  Package: arduino 1:1.0+dfsg-9
>  ProcVersionSignature: Ubuntu 3.2.0-24.37-generic 3.2.14
>  Uname: Linux 3.2.0-24-generic i686
>  ApportVersion: 2.0.1-0ubuntu7
>  Architecture: i386
>  Date: Mon May 14 09:23:39 2012
>  InstallationMedia: Ubuntu 11.04 "Natty Narwhal" - Release i386 (20110427.1)
>  PackageArchitecture: all
>  ProcEnviron:
>   LANGUAGE=en_US:en
>   TERM=xterm
>   PATH=(custom, user)
>   LANG=en_US.UTF-8
>   SHELL=/bin/bash
>  SourcePackage: arduino
>  UpgradeStatus: Upgraded to precise on 2012-05-06 (7 days ago)
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/ubuntu/+source/arduino/+bug/998952/+subscriptions
>
> _______________________________________________
> Developers mailing list
> <email address hidden>
> http://arduino.cc/mailman/listinfo/developers_arduino.cc

--
Software Engineer
+15105575986

Revision history for this message
kaedenn (kaedenn) wrote :

The fix is simple. Edit the arduino shell script and make the following modification:

- java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel processing.app.Base
+ java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel processing.app.Base "$@"

The shell script can be found by typing `which arduino' into your shell.

This worked for me, however YMMV.

Revision history for this message
Scott Howard (showard314) wrote : Re: [Bug 998952] Re: Open With Ardunio, File Open Fails

On Sun, May 13, 2012 at 11:30 PM, kaedenn <email address hidden> wrote:
> The fix is simple. Edit the arduino shell script and make the following
> modification:
>
> - java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel processing.app.Base
> + java -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel processing.app.Base "$@"

Awesome, i tested it and it works. I uploaded it to Debian
experimental. Whenever 1.0.1 is released I'll upload it to unstable
and then it will be synced to Ubuntu.

~Scott

Revision history for this message
arky (arky) wrote :

Thanks, I have patched in upstream on github and put in a pull request.

https://github.com/arky/Arduino/commit/26cd9e8c6438a1292a3101aba3a8c432cf73b222

Changed in arduino (Ubuntu):
status: New → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package arduino - 1:1.0.1+dfsg-1

---------------
arduino (1:1.0.1+dfsg-1) unstable; urgency=low

  * New upstream release.

 -- Scott Howard <email address hidden> Tue, 22 May 2012 09:26:04 -0400

Changed in arduino (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
steve david (cactus5517) wrote :

I have trouble using Ubuntu 14.04 with Arduino. Are there patches to remedy this problem?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.