Earlier quoted context omitted.
Step1: Write a test. Step2, IDE: Right click + Run. Step2, CLI: $ run Bonus: The test is now part of your automated test suite, and will be ran many times to ensure things don't break.
Now try to fix the code from the unit test when it breaks and redo the unit test, from the point where it broke.
REPL vs CLI: IDE wars
91–100 of 110 posts
Re: REPL vs CLI: IDE wars
#92Re: REPL vs CLI: IDE wars
#93I think you might be missing the main "aha!" of clojure REPLs vs REPLs in non-homoiconic languages: you can very easily execute small parts of the program you're editing without re-typing the code. In emacs, for instance, you often use `eval-last-sexp`, by default bound to C-x C-e. This lets you move your cursor to a particular point in the file, often deep in a function, and get the results of just the form(s) you'r…
> In emacs, for instance, you often use `eval-last-sexp`, by default bound to C-x C-e. This lets you move your cursor to a particular point in the file, often deep in a function, and get the results of just the form(s) you're pointing at. but that depends on how the environment is looking at the time. during development, in scheme, i just have a function (reset) that reloads all the files of an app. sometimes i creat…
Re: REPL vs CLI: IDE wars
#94Earlier quoted context omitted.
"man set" can't provide that information trivially without knowing your shell; dash/bash/ksh/zsh will all be subtly different. However, if you are running bash, "help set" is fine. FWIW, I really don't like pipefail as a default (e.g. piping to "head" causes random pipefails) and -e also has some confusing semantics. Also either failglob or nullglob are more important than either and -C is useful for some scripts as…
> (set -e; echo hi); echo $? It works in my shell. :-/ It looks like you forgot to insert `false` command. You are pointing to the problem with -e not working in subshell/deep functions, because of POSIX. Right? It's described in bash documentation: http://www.gnu.org/software/bash/manual/html_node/The-Set-Bu... > I think just defining a die() function and using it after any command that must succeed is more verbose,…
https://gist.github.com/zachriggle/8574964d2e3078cdfae84b574...
e.g.
An error occurred on ./test:18
Frame 1 (./test:21)
18 false
19 }
20
21 >>> a
Frame 2 (./test:6)
3 source TRAPERR.zsh
4
5 a() {
6 >>> b
7 }
8
9 b() {
Frame 3 (./test:10)
7 }
8
9 b() {
10 >>> c
11 }
12
13 c() {
Frame 4 (./test:14)
11 }
12
13 c() {
14 >>> d
15 }
16
17 d() {
Frame 5 (./test:18)
15 }
16
17 d() {
18 >>> false
19 }
20
21 aRe: REPL vs CLI: IDE wars
#95Earlier quoted context omitted.
And I recommend trying out Smalltalk.
As a hobby I want to learn a lisp. Where should I begin? :)
Re: REPL vs CLI: IDE wars
#96Earlier quoted context omitted.
Off-topic, but Bash's manpage is awful and a great demonstration of the limitation of manpages. Not that the content is bad (it's great!), but as OP (and you) demonstrated, finding relevant information is close to impossible in the humongous document. In Bash's defense, its manpage is a concession to people's habits, and its documentation really rests in its Info page. Except that doesn't seem to be popular either (I…
Contrary to typical GNU practice, the bash info manual states that it is intended as a “ brief introduction” and that the man page is the definitive reference on shell behavior: https://www.gnu.org/software/bash/manual/html_node/index.htm...
Re: REPL vs CLI: IDE wars
#97Earlier quoted context omitted.
> In emacs, for instance, you often use `eval-last-sexp`, by default bound to C-x C-e. This lets you move your cursor to a particular point in the file, often deep in a function, and get the results of just the form(s) you're pointing at. but that depends on how the environment is looking at the time. during development, in scheme, i just have a function (reset) that reloads all the files of an app. sometimes i creat…
Python can hot-reload an application from scratch, too. The idea here is to not reload everything from scratch, but to redefine functions incrementally/iteratively as you work.
Re: REPL vs CLI: IDE wars
#98Earlier quoted context omitted.
i get the magical aspect of repls in scheme and CL. not in clojure. not sure why. so i don't like clojure, but i feel like i should ?? why is that?
As I said, I think Clojure is significantly iimpacted in how much dynamic reconfiguration it can handle by compiling down to the JVM. Still, personally I have little to no experience with Clojure, so I can't really comment too deeply.
Re: REPL vs CLI: IDE wars
#99Earlier quoted context omitted.
i've used emacs for 20 years. i still spend 80% of my day in it ... and vscode is vastly superior for development.
The thing that bugs me about the IDEs is how slow they are. I'm super productive in them, but I really don't feel like they need to be so slow. I'm not even talking about the indexing which I get. In fact they weren't always unresponsive, seems Jetbrain's products have regressed in the last year, but mostly Webstorm. I use WS on OSX and Win10, and on both I get all kinds of slowdowns - different projects too. Tried d…
Re: REPL vs CLI: IDE wars
#100This post could be summarized as "write as much of your project's tooling as you can in the project's main programming language and the project's main programming language should be Clojure" and I agree wholeheartedly.
I think their point is bigger than that. Historically one of the major points against using Clojure to write your tooling was the slow startup times which are just painful from the CLI. It looks like the clj-exec idea linked to in the article is the secret sauce that makes moving to writing your tooling in Clojure a workable idea, since now you have a unified calling convention for both calling tooling from the REPL…