Is there a command to trigger stub generation?
i missed that the other day too... also, i have a monorepo with 4-5 clojure projects in it now and im being asked 4-5 times whether i want to generate stubs. that would be great if i could just say yes 1 time 🙂
There isn’t, but there should be. You can provoke the check by refreshing your lein/deps project from the corresponding toolwindow as a workaround.
@onetom You should only be asked once for that, I think. Do you mean you have multiple deps projects in a single IntelliJ project?
yes. i have multiple deps modules
if i understand correctly, we should version control the .idea/clojure-deps.xml
files.
they contain system aliases though, which might not be present on other systems.
those are not transferrable to other machines and iirc they got cleaned up automatically, resulting in an unnecessary churn in changes to this file.
what can we do about it?
would it make sense to put the system aliases into a different file, which can be gitignored?
of course turning aliases on and off might also result in changes to the .iml
files of other the intellij deps modules, eg:
- <orderEntry type="library" name="Deps: vlaaad/reveal:d0fe22" level="project" />
+ <orderEntry type="library" name="Deps: Local vlaaad/reveal" level="project" />
i have no idea what to do about that.and the alias checkboxes are still buggy. if i click them nothing seems to happen, but if i move up/down in the alias tree, then they update and reflect the new state. initially i thought it should be just my system, but i've seen the same behaviour on 3 other machines too, so i think it's a bug
hmmm... my run configurations i put in .run/
are not showing up amongst the other ones, which are still under .idea/runConfigurations
.
how can i make cursive aware of the ones in .run/
?
i've also noticed that one of those files have a lot of repetition in them. smells like a bug:
xml
<component name="ProjectRunConfigurationManager">
<configuration default="false" name="Rule Crib" type="ClojureREPL" factoryName="Local" activateToolWindowBeforeRun="false" singleton="true">
<module name="rule-crib" />
<setting name="replType" value="NREPL" />
<setting name="execution" value="DEPS" />
<setting name="jvmArgs" value="" />
<setting name="parameters" value="" />
<setting name="workingDir" value="$PROJECT_DIR$/rule-crib" />
<setting name="profiles" value="" />
<setting name="aliases" value="datomic-peer,expect,dev" />
<setting name="fixLineNumbers" value="false" />
<method v="2" />
</configuration>
<configuration default="false" name="Rule Crib" type="ClojureREPL" factoryName="Local" activateToolWindowBeforeRun="false" singleton="true">
<module name="rule-crib" />
<setting name="replType" value="NREPL" />
<setting name="execution" value="DEPS" />
<setting name="jvmArgs" value="" />
<setting name="parameters" value="" />
<setting name="workingDir" value="$PROJECT_DIR$/rule-crib" />
<setting name="profiles" value="" />
<setting name="aliases" value="datomic-peer,expect,dev" />
<setting name="fixLineNumbers" value="false" />
<method v="2" />
</configuration>
<configuration default="false" name="Rule Crib" type="ClojureREPL" factoryName="Local" activateToolWindowBeforeRun="false" singleton="true">
<module name="rule-crib" />
<setting name="replType" value="NREPL" />
<setting name="execution" value="DEPS" />
<setting name="jvmArgs" value="" />
<setting name="parameters" value="" />
<setting name="workingDir" value="$PROJECT_DIR$/rule-crib" />
<setting name="profiles" value="" />
<setting name="aliases" value="datomic-peer,expect,dev" />
<setting name="fixLineNumbers" value="false" />
<method v="2" />
</configuration>
<configuration default="false" name="Rule Crib" type="ClojureREPL" factoryName="Local" activateToolWindowBeforeRun="false" singleton="true">
<module name="rule-crib" />
<setting name="replType" value="NREPL" />
<setting name="execution" value="DEPS" />
<setting name="jvmArgs" value="" />
<setting name="parameters" value="" />
<setting name="workingDir" value="$PROJECT_DIR$/rule-crib" />
<setting name="profiles" value="" />
<setting name="aliases" value="datomic-peer,expect,dev" />
<setting name="fixLineNumbers" value="false" />
<method v="2" />
</configuration>
<configuration default="false" name="Rule Crib" type="ClojureREPL" factoryName="Local" activateToolWindowBeforeRun="false" singleton="true">
<module name="rule-crib" />
<setting name="replType" value="NREPL" />
<setting name="execution" value="DEPS" />
<setting name="jvmArgs" value="" />
<setting name="parameters" value="" />
<setting name="workingDir" value="$PROJECT_DIR$/rule-crib" />
<setting name="profiles" value="" />
<setting name="aliases" value="datomic-peer,expect,dev" />
<setting name="fixLineNumbers" value="false" />
<method v="2" />
</configuration>
<configuration default="false" name="Rule Crib" type="ClojureREPL" factoryName="Local" activateToolWindowBeforeRun="false" singleton="true">
<module name="rule-crib" />
<setting name="replType" value="NREPL" />
<setting name="execution" value="DEPS" />
<setting name="jvmArgs" value="" />
<setting name="parameters" value="" />
<setting name="workingDir" value="$PROJECT_DIR$/rule-crib" />
<setting name="profiles" value="" />
<setting name="aliases" value="datomic-peer,expect,kaocha,dev" />
<setting name="fixLineNumbers" value="false" />
<method v="2" />
</configuration>
</component>
I’m not sure, actually. How are you putting them under .run/
?
Oh, I see - there’s a “Store configuration file in…” option - I think that’s new, or at least I don’t remember seeing it previously.
originally they were added under the old location, then the other day i clicked on that cog next to the Store as project file and changed the path to .run
oh, that's not a cursive feature?
Could you file an issue for that? I’m not sure what’s going on there. It looks to me like they’re expecting run configs to be in one location, rather than two.
No, that’s IntelliJ doing that.
But that you can now specify what that location should be.
aaah... so that's supposed to be a per-project option, not a per run-config! it's not clear from the UI...
beacuse it shows different paths for the different run configs
so the references to the run configs are stored in workspace.xml
, which is not under version control (and correctly so), so im not sure how this new feature is meant to work... 😕
also, i think i've started intellij community editor over this project recently and that might have tangled these settings up, since i had some python run configs too, which are not supported under the CE
workspace.xml
has this kind of magic too, to deal with chaning the run config location:
<component name="ChangeListManager">
<list default="true" id="73adb5ea-abbc-47f9-83c2-475bd4854522" name="Default Changelist" comment="Reveal integration and documentation">
<change beforePath="$PROJECT_DIR$/.idea/runConfigurations/Datomic_testbed.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.run/Datomic testbed.run.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/runConfigurations/Recurrence_REPL.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.run/Recurrence REPL.run.xml" afterDir="false" />
...
</list>
Seems like structural editing choices don't show up anymore in the taskbar. Even though they are selected to be shown. Disabling the selection and re-enabling it won't matter.
@cfleming sorry, missed your question but I had answered that just in the next message 🙂 The version was 1.9.3-2020.2
Just got an update to 1.9.4-eap1-2020.2 where this issue seems to have gone away 👍
Version 1.9.3-2020.2
On OSX what's the key binding to send the currently highlighted form (even if it's nested inside another form?) to the REPL? I'm using <CMD>+p
and that's great but would be cool to send just a nested bit of the form
I'm failing to find it so I figured I'd just ask, thanks!
I've also assigned Ctrl-Enter
(aka Cmd-Shift-P
) to Eval top form
and Ctrl-Shift-Enter
to Eval form before caret
, so I can just move to the end of a form and Ctrl-Shift-Enter
just that. it's often followed by a Ctrl-Enter
to eval the whole, containing form too if I were happy with the evaluation result of the sub-form.
on that note, i often find myself wanting to evaluate a sub-form, which comes right after my cursor.
i was wondering if it would be possible to create a composite action, which does all this at once.
if there is an ambiguity, maybe a popup can show the alternatives, just like the variable extraction popup.
the rules could be similar to how the Alt-Up
Extend Selection decides what to highlight, but favoring sequences as opposed to individual tokens.
in other words, when i press ctrl-shift-enter
, i would like it to be the combination of a more greedy alt-up
+ ctrl-enter
.
i could describe such an action as Eval around caret or Eval in caret's vincinity
The problem with these sorts of actions is the combinatorial explosion of <form selection>/<how to eval>/<what to do with the results>. Lots of people have asked for an eval which puts the result in a comment in the source file. So I’m planning to extend the REPL commands feature to allow people to build the particular commands they want out of component pieces.