Java for Small Coding Tasks
summary
Argues Java is practical for small scripts by showing concrete tooling and demos: the Java launcher compiles in memory so no class files, unnamed classes let files omit boilerplate, IO.print/on and a magic import simplify code, and a backup script that randomly picks 10 files and verifies restore runs as a single file. Demonstrates a Zoom audio auto-switcher that works, shows JShell for regex fiddling, and uses JBang to fetch Maven deps via pseudo-comments; a Graal native image build runs about 4× faster.
AI-written summary · about
chapters (15)
- 0:00Introduction
- 0:53Why small Java?
- 5:07Launching scripts without compiling
- 8:28Implicit classes and main methods
- 11:50Using records for data
- 13:50Helpful language features
- 16:56Standard library for scripts
- 19:19Managing dependencies
- 23:22Exception handling in scripts
- 25:33File organization and IDE support
- 28:16Using Graal native images
- 29:23JShell and exploration
- 31:56JBang for scripting
- 34:11Jupyter notebooks in Java
- 44:06Conclusion
related talks
51mThe Best of Java Shorts Show: 100 Snippets in 50 Minutes
44mThe Best of Java Shorts Shorts Show: 100 Snippets in 45 Minutes
14mShare Your Java CLI Apps with Ease
45mAdvanced "Java 101"
18mJBang, a Java file to rule them all? 💍
41mJava Made (Somewhat) Simple
47mJava's Hidden Gems: Tools and Libraries
39mJava's Hidden Gems: Tools and Libraries
