{"id":21633746,"url":"https://github.com/dgroomes/jshell-playground","last_synced_at":"2026-05-15T22:05:37.983Z","repository":{"id":55386825,"uuid":"293701402","full_name":"dgroomes/jshell-playground","owner":"dgroomes","description":"📚 Learning and exploring JShell—the official Java shell and read-eval-print loop (REPL)","archived":false,"fork":false,"pushed_at":"2025-08-09T16:56:55.000Z","size":2206,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-09T17:31:49.170Z","etag":null,"topics":["java","jshell","jshell-repl","learning-by-doing"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dgroomes.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-09-08T04:32:28.000Z","updated_at":"2025-08-09T16:56:59.000Z","dependencies_parsed_at":"2024-08-03T19:46:31.385Z","dependency_job_id":null,"html_url":"https://github.com/dgroomes/jshell-playground","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dgroomes/jshell-playground","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgroomes%2Fjshell-playground","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgroomes%2Fjshell-playground/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgroomes%2Fjshell-playground/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgroomes%2Fjshell-playground/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dgroomes","download_url":"https://codeload.github.com/dgroomes/jshell-playground/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dgroomes%2Fjshell-playground/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279010174,"owners_count":26084691,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-12T02:00:06.719Z","response_time":53,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["java","jshell","jshell-repl","learning-by-doing"],"created_at":"2024-11-25T03:13:40.174Z","updated_at":"2025-10-12T03:15:57.532Z","avatar_url":"https://github.com/dgroomes.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# jshell-playground\n\n📚 Learning and exploring JShell—the official Java shell and read-eval-print loop (REPL).\n\n\n## Overview\n\nJava is infamously awkward to get up and running with for beginner programmers. `public static void main(String[] args)`... really?\nAnd the `main` method must be wrapped in a class. And the compile and run steps must be in separate commands (until [JEP-330](https://openjdk.java.net/jeps/330) anyway).\nOverall, a prototypical \"hello world\" program is just too hard compared to other languages.\n \n🚀 JShell to the rescue!\n\nJShell removes all of those requirements and enables a beginner programmer to start learning and exploring Java\nwithout all the fuss! This project is my attempt to learn about JShell and share my findings.\n\n\n## Quick start\n\nStart with the [basic/](basic/) subproject.\n\n\n## Learn about JShell\n\nThe JDK Enhancement Proposal that introduced JShell is the best place to learn the \"what\" and \"why\" about it: \u003chttp://openjdk.java.net/jeps/222\u003e.\n\nTo learn the \"how\", see the [*Introduction to JShell* article](https://docs.oracle.com/en/java/javase/14/jshell/introduction-jshell.html#GUID-630F27C8-1195-4989-9F6B-2C51D46F52C8).\n\nSome highlights from the JEP page include:\n\n\u003e Provide an interactive tool to evaluate declarations, statements, and expressions of the Java programming language, together with an API so that other applications can leverage this functionality.\n\n\u003e Out of scope are graphical interfaces and debugger support. The JShell API is intended to allow JShell functionality in IDEs and other tools, but the jshell tool is not intended to be an IDE.\n\n\u003e Immediate feedback is important when learning a programming language and its APIs. The number one reason schools cite for moving away from Java as a teaching language is that other languages have a \"REPL\" and have far lower bars to an initial \"Hello, world!\" program.\n\n\u003e Exploration of coding options is also important for developers prototyping code or investigating a new API. Interactive evaluation is vastly more efficient in this regard than edit/compile/execute and System.out.println.\n\n\n## Standalone subprojects\n\nThis repository illustrates different concepts, patterns and examples via standalone subprojects. Each subproject is\ncompletely independent of the others and do not depend on the root project. This _standalone subproject constraint_\nforces the subprojects to be complete and maximizes the reader's chances of successfully running, understanding, and\nre-using the code.\n\nThe subprojects include:\n\n\n### `basic/`\n\nStart a `jshell` (the JShell command-line tool) session that's loaded with your own application source code. It is beginner-friendly!\n\nSee the README in [basic/](basic/).\n\n\n### `with-libraries/`\n\nThis subproject is similar to `basic/` buts adds a few external Java libraries (including [Jackson](https://github.com/FasterXML/jackson)).\n\nSee the README in [with-libraries/](with-libraries/).\n\n\n### `with-gradle/`\n\nThis subproject showcases an idiomatic Gradle-based Java project that is extended with a custom Gradle plugin that helps\nyou run a `jshell` session with the project's source code and library dependencies.\n\nSee the README in [with-gradle/](with-gradle/).\n\n\n### `api/`\n\nExplore the JShell API by implementing a custom event loop.\n\nSee the README in [api/](api/).\n\n\n## WishList\n\nGeneral clean-ups, TODOs and things I wish to implement for this project:\n\n* [x] DONE Implement `basic/`\n* [ ] SKIPPED (no, not possible) Can we execute `jshell` without compiling the program source code? Similar to the single-file source code support?\n* [x] DONE Implement `with-gradle/`. It should be taken directly from \u003chttps://github.com/dgroomes/gradle-playground/tree/main/plugin\u003e.\n* [x] DONE Can the `basic` and `with-libraries` subprojects be define as Gradle \"included builds\"? To be clerr, they are not\n  Gradle projects but to get the convenience of \"Clone a repo and open it in the IDE\" I want to technically define them\n  as Gradle projects using the root `build.gradle.kts` (does not exist yet). I'm not sure how to re-defined the path to the\n  \"source sets\" (i.e `src/` instead of the traditional Maven/Gradle `src/main/java/`).\n* [x] DONE (well, not perfectly) Use the name \"JShell\" where appropriate instead of `jshell`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdgroomes%2Fjshell-playground","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdgroomes%2Fjshell-playground","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdgroomes%2Fjshell-playground/lists"}