IDE for Linux


(Cyril Graze) #1

Hi all,

I'm excited that Swift is now available in Linux. I've installed it
following the guides available and am ready to go. However, I've been using
the Atom IDE, which is fine, but not exactly geared towards to Swift
development.

Since XCode is not available, what do you recommend for programming Swift
in Linux?

thanks


(Dmitri Gribenko) #2

Hi Cyril,

I have been using vim. Other people have used emacs. You can find
editor support code here:

https://github.com/apple/swift/tree/master/utils/vim
https://github.com/apple/swift/blob/master/utils/swift-mode.el

Dmitri

···

On Thu, Dec 3, 2015 at 3:14 PM, Cyril Graze <cgraze@gmail.com> wrote:

Hi all,

I'm excited that Swift is now available in Linux. I've installed it following the guides available and am ready to go. However, I've been using the Atom IDE, which is fine, but not exactly geared towards to Swift development.

Since XCode is not available, what do you recommend for programming Swift in Linux?

--
main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if
(j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr@gmail.com>*/


(Cyril Graze) #3

Hi Dmitri,

Thanks for the response. Is there any IDE that will allow me to design the
visual layout of the user interface as is possible in Xcode?

I'd like to code an iPhone app, and not sure if this is something I can do
on vim?

thanks

···

On Thu, Dec 3, 2015 at 5:18 PM, Dmitri Gribenko <gribozavr@gmail.com> wrote:

On Thu, Dec 3, 2015 at 3:14 PM, Cyril Graze <cgraze@gmail.com> wrote:
>
> Hi all,
>
> I'm excited that Swift is now available in Linux. I've installed it
following the guides available and am ready to go. However, I've been using
the Atom IDE, which is fine, but not exactly geared towards to Swift
development.
>
> Since XCode is not available, what do you recommend for programming
Swift in Linux?

Hi Cyril,

I have been using vim. Other people have used emacs. You can find
editor support code here:

https://github.com/apple/swift/tree/master/utils/vim
https://github.com/apple/swift/blob/master/utils/swift-mode.el

Dmitri

--
main(i,j){for(i=2;;i++){for(j=2;j<i;j++){if(!(i%j)){j=0;break;}}if
(j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr@gmail.com>*/


(Joe Groff) #4

Developing iPhone apps will likely only ever be officially supported on Macs running Xcode. You won't be able to build iPhone apps using Swift on Linux.

-Joe

···

On Dec 3, 2015, at 3:26 PM, Cyril Graze <cgraze@gmail.com> wrote:

Hi Dmitri,

Thanks for the response. Is there any IDE that will allow me to design the visual layout of the user interface as is possible in Xcode?

I'd like to code an iPhone app, and not sure if this is something I can do on vim?


(Jens Alfke) #5

Yup. The Linux version of Swift is for building code that runs on Linux. If you wanted it to build code that runs on iOS there are a bajillion other things you’d need that aren’t included — ARM cross-compilation, Mach-O executable generation, integrating with Apple’s Objective-C ABIs, a full set of headers for the iOS frameworks, and so on.

—Jens

···

On Dec 3, 2015, at 3:32 PM, Joe Groff <jgroff@apple.com> wrote:

Developing iPhone apps will likely only ever be officially supported on Macs running Xcode. You won't be able to build iPhone apps using Swift on Linux.


(Cyril Graze) #6

Hi Joe,

Thanks for the heads up. So what type of target applications are possible
in Linux, just CLI?

Is it possible to develop any type of application with a GUI?

···

On Thu, Dec 3, 2015 at 5:32 PM, Joe Groff <jgroff@apple.com> wrote:

On Dec 3, 2015, at 3:26 PM, Cyril Graze <cgraze@gmail.com> wrote:

Hi Dmitri,

Thanks for the response. Is there any IDE that will allow me to design the
visual layout of the user interface as is possible in Xcode?

I'd like to code an iPhone app, and not sure if this is something I can do
on vim?

Developing iPhone apps will likely only ever be officially supported on
Macs running Xcode. You won't be able to build iPhone apps using Swift on
Linux.

-Joe


(Jens Alfke) #7

Sure. It’s pretty straightforward to call C APIs from Swift. You just need to learn your way around a few glue classes like UnsafePointer*. The best reference for now would be Apple’s book Using Swift With Cocoa And Objective-C. I don’t think that book is part of the open-source drop, but you can get it for free from the iBooks store.

—Jens

* Just be careful to encapsulate all the unsafe parts of the code into a class or module that exposes a safe API, then use that API in your app code itself. If you go sprinkling unsafe stuff all over your app, it’s going to be really nasty to debug...

···

On Dec 3, 2015, at 3:36 PM, Cyril Graze <cgraze@gmail.com> wrote:

Is it possible to develop any type of application with a GUI?