Thanks for pointing out that the Julia process should be running in the background.
It turned out that the problem for Julia autocompletion was caused by "non-global" global autocomplete mode. I've managed to find a function that defined behaviour that I was looking for here: http://emacswiki.org/emacs/AutoComplete#toc6 Once again, thank you for your help! Best, Ivan среда, 28 октября 2015 г., 2:21:47 UTC+1 пользователь Ista Zahn написал: > > Does tab completion work in other languages supported by ESS? If it > doesn't then there would appear to be something missing from your ESS > settings (I don't bind completion to TAB myself, there is too much > already happening on the TAB key). If it works for (e.g.) R but not > Julia I would report a bug to ESS. > > For me completion of my own functions and objects works fine. You do > have to evaluate them in the REPL though. ESS completion works be > asking the running REPL for completions, so if the object hasn't been > defined there it won't show up in the completion list. > > As for 'fun' completing to 'functionloc', yeah, that's what I see too. > I think it doesn't work for the same reason '@doc function' doesn't > work. I'm sure ESS bug reports and pull requests would be appreciated. > > Best, > Ista > > On Tue, Oct 27, 2015 at 5:12 PM, Ivan Bocharov <[email protected] > <javascript:>> wrote: > > Thank you very much for your reply! > > > > I have Compat package installed, julia process running and tried both > > autocomplete and company. TAB-completion still doesn't work, though, > > invoking C-M-i produces some results. The thing is that i can complete > only > > the contents from the Base (some types and functions) and can't complete > my > > own functions and objects. Also, for example, 'func' completes to > > 'functionloc'. Is this the desired behaviour? > > > > Best, > > Ivan > > > > вторник, 27 октября 2015 г., 15:38:13 UTC+1 пользователь Ista Zahn > написал: > >> > >> It works for me with the company backend. Haven't tried the > >> autocomplete backend recently. I think ESS prefers the company > >> backend, so just installing and loading the company package may be > >> enough. > >> > >> Note that for completions to work you need to have an inferior julia > >> process running, and the Julia Compat package must be installed. > >> > >> Best, > >> Ista > >> > >> On Tue, Oct 27, 2015 at 4:44 AM, Ivan Bocharov <[email protected]> > wrote: > >> > Hello All, > >> > > >> > I am a newbie Emacs user and I really want to write my Julia code in > >> > Emacs. > >> > I've installed Emacs using brew and ESS from MELPA. > >> > > >> > I can get TAB-autocompletion in Julia shell, but the autocompletion > >> > doesn't > >> > work in my own scripts. Is it supposed to be this way or am I missing > >> > something? > >> > > >> > My current setup is: Emacs from brew (GNU Emacs 24.5.1), Julia > v.0.4.0 > >> > and > >> > ESS v. 15.09-1 (output from M-x ess-version). > >> > > >> > My init.el file looks this way: > >> > > >> > (when (>= emacs-major-version 24) > >> > (require 'package) > >> > (add-to-list > >> > 'package-archives > >> > '("melpa" . "http://melpa.org/packages/") > >> > t) > >> > (package-initialize)) > >> > > >> > (require 'ess-site) > >> > (setq inferior-julia-program-name "julia") > >> > (setq ess-use-auto-complete t) > >> > (setq ess-tab-complete-in-script t) > >> > > >> > (require 'auto-complete-config) > >> > (add-to-list 'ac-dictionary-directories > >> > "~/.emacs.d/elpa/auto-complete/dict") > >> > > >> > (set-default 'ac-sources > >> > '(ac-source-abbrev > >> > ac-source-dictionary > >> > ac-source-yasnippet > >> > ac-source-words-in-buffer > >> > ac-source-words-in-same-mode-buffers > >> > ac-source-semantic)) > >> > > >> > (ac-config-default) > >> > > >> > As a side note I wanted to thank all the contributors and the > community > >> > for > >> > their work! > >> > > >> > Best, Ivan. >
