commit 5bca2e3

Artur Manuel  ·  2025-09-07 02:28:42 +0000 UTC
parent 9c5c2f1
feat(meson): remove meson, use makefile and gradle (and rewrite java to kotlin)
23 files changed,  +651, -106
+2, -2
 1@@ -40,8 +40,8 @@
 2 # debug information files
 3 *.dwo
 4 
 5-# Meson
 6-build/
 7+# Makefile
 8+target/
 9 
10 # clangd
11 .cache
+13, -0
 1@@ -0,0 +1,13 @@
 2+CXX= 	clang++
 3+
 4+TARGETDIR= 	./target
 5+PREFIX?= 	/usr/local
 6+BINDIR= 	$(PREFIX)/bin
 7+
 8+rosetta_collatz:
 9+	mkdir -p $(TARGETDIR)/bin
10+	$(CXX) -std=c++23 -o $(TARGETDIR)/bin/rosetta_collatz src/rosetta_collatz.cpp
11+
12+install: all
13+	mkdir -p $(BINDIR)
14+	install -Dm755 $(TARGETDIR)/bin/rosetta-collatz $(BINDIR)
+0, -11
 1@@ -1,11 +0,0 @@
 2-project(
 3-  'rosetta-collatz',
 4-  'cpp',
 5-  version: '0.1',
 6-  default_options: [
 7-    'warning_level=3',
 8-    'cpp_std=c++23',
 9-  ]
10-)
11-
12-subdir('./src')
+0, -7
1@@ -1,7 +0,0 @@
2-exe = executable(
3-  'rosetta-collatz',
4-  'rosetta_collatz.cpp',
5-  install: true
6-)
7-
8-test('basic', exe)
+13, -0
 1@@ -0,0 +1,13 @@
 2+CC= 	clang
 3+
 4+TARGETDIR= 	./target
 5+PREFIX?= 	/usr/local
 6+BINDIR= 	$(PREFIX)/bin
 7+
 8+rosetta_collatz:
 9+	mkdir -p $(TARGETDIR)/bin
10+	$(CC) -std=c++23 -o $(TARGETDIR)/bin/rosetta_collatz src/rosetta_collatz.c
11+
12+install: all
13+	mkdir -p $(BINDIR)
14+	install -Dm755 $(TARGETDIR)/bin/rosetta-collatz $(BINDIR)
+0, -11
 1@@ -1,11 +0,0 @@
 2-project(
 3-  'rosetta-collatz',
 4-  'c',
 5-  version: '0.1',
 6-  default_options: [
 7-    'warning_level=3',
 8-    'c_std=c23',
 9-  ]
10-)
11-
12-subdir('src')
+0, -4
1@@ -1,4 +0,0 @@
2-exe = executable('rosetta-collatz', 'rosetta_collatz.c',
3-  install : true)
4-
5-test('basic', exe)
+0, -27
 1@@ -1,27 +0,0 @@
 2-# Compiled class file
 3-*.class
 4-
 5-# Log file
 6-*.log
 7-
 8-# BlueJ files
 9-*.ctxt
10-
11-# Mobile Tools for Java (J2ME)
12-.mtj.tmp/
13-
14-# Package Files #
15-*.jar
16-*.war
17-*.nar
18-*.ear
19-*.zip
20-*.tar.gz
21-*.rar
22-
23-# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
24-hs_err_pid*
25-replay_pid*
26-
27-# meson
28-build/
+0, -10
 1@@ -1,10 +0,0 @@
 2-project(
 3-  'rosetta_collatz',
 4-  'java',
 5-  version: '0.1',
 6-  default_options: [
 7-    'warning_level=3',
 8-  ],
 9-)
10-
11-subdir('src')
+0, -8
1@@ -1,8 +0,0 @@
2-exe = jar(
3-  'rosetta_collatz',
4-  'rosetta_collatz.java',
5-  main_class: 'rosetta_collatz',
6-  install: true
7-)
8-
9-test('basic', exe)
+0, -26
 1@@ -1,26 +0,0 @@
 2-public class rosetta_collatz {
 3-    static public int collatz(int a) {
 4-        if (a % 2 == 0)
 5-            return a / 2;
 6-        return 3 * a + 1;
 7-    }
 8-
 9-    static public String collatzSequence(int a) {
10-        String result = String.format("%d: ", a);
11-        for (int i = a; i >= 1; i = collatz(i)) {
12-            if (i == 1) {
13-                result += "1";
14-                break;
15-            }
16-            result += String.format("%d, ", i);
17-        }
18-        return result;
19-    }
20-
21-    public static void main(String args[]) {
22-        for (int i = 1; i <= 10000; i++) {
23-            System.out.println(collatzSequence(i));
24-        }
25-    }
26-}
27-
+12, -0
 1@@ -0,0 +1,12 @@
 2+#
 3+# https://help.github.com/articles/dealing-with-line-endings/
 4+#
 5+# Linux start script should use lf
 6+/gradlew        text eol=lf
 7+
 8+# These are Windows script files and should use crlf
 9+*.bat           text eol=crlf
10+
11+# Binary files should be left untouched
12+*.jar           binary
13+
+126, -0
  1@@ -0,0 +1,126 @@
  2+### Windows template
  3+# Windows thumbnail cache files
  4+Thumbs.db
  5+Thumbs.db:encryptable
  6+ehthumbs.db
  7+ehthumbs_vista.db
  8+
  9+# Dump file
 10+*.stackdump
 11+
 12+# Folder config file
 13+[Dd]esktop.ini
 14+
 15+# Recycle Bin used on file shares
 16+$RECYCLE.BIN/
 17+
 18+# Windows Installer files
 19+*.cab
 20+*.msi
 21+*.msix
 22+*.msm
 23+*.msp
 24+
 25+# Windows shortcuts
 26+*.lnk
 27+
 28+### macOS template
 29+# General
 30+.DS_Store
 31+.AppleDouble
 32+.LSOverride
 33+
 34+# Icon must end with two \r
 35+Icon
 36+
 37+# Thumbnails
 38+._*
 39+
 40+# Files that might appear in the root of a volume
 41+.DocumentRevisions-V100
 42+.fseventsd
 43+.Spotlight-V100
 44+.TemporaryItems
 45+.Trashes
 46+.VolumeIcon.icns
 47+.com.apple.timemachine.donotpresent
 48+
 49+# Directories potentially created on remote AFP share
 50+.AppleDB
 51+.AppleDesktop
 52+Network Trash Folder
 53+Temporary Items
 54+.apdisk
 55+
 56+### Linux template
 57+*~
 58+
 59+# temporary files which can be created if a process still has a handle open of a deleted file
 60+.fuse_hidden*
 61+
 62+# KDE directory preferences
 63+.directory
 64+
 65+# Linux trash folder which might appear on any partition or disk
 66+.Trash-*
 67+
 68+# .nfs files are created when an open file is removed but is still being accessed
 69+.nfs*
 70+
 71+### JetBrains template
 72+# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm
 73+# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
 74+
 75+*.iml
 76+*.ipr
 77+*.iws
 78+/.idea/*
 79+
 80+# Exclude non-user-specific stuff
 81+!.idea/.name
 82+!.idea/codeInsightSettings.xml
 83+!.idea/codeStyles/
 84+!.idea/copyright/
 85+!.idea/dataSources.xml
 86+!.idea/detekt.xml
 87+!.idea/encodings.xml
 88+!.idea/externalDependencies.xml
 89+!.idea/file.template.settings.xml
 90+!.idea/fileTemplates/
 91+!.idea/icon.svg
 92+!.idea/inspectionProfiles/
 93+!.idea/runConfigurations/
 94+!.idea/scopes/
 95+!.idea/vcs.xml
 96+
 97+### Kotlin template
 98+# Compiled class file
 99+*.class
100+
101+# Log file
102+*.log
103+
104+# Package Files #
105+*.jar
106+*.war
107+*.nar
108+*.ear
109+*.zip
110+*.tar.gz
111+*.rar
112+
113+# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
114+hs_err_pid*
115+
116+### Gradle template
117+.gradle
118+
119+# Note that you may need to exclude by hand other folders
120+# named build if necessary (e.g., in src/)
121+**/build/
122+
123+# Avoid ignoring Gradle wrapper jar file (.jar files are usually ignored)
124+!gradle/wrapper/gradle-wrapper.jar
125+
126+# Cache of project
127+.gradletasknamecache
+49, -0
 1@@ -0,0 +1,49 @@
 2+/*
 3+ * This file was generated by the Gradle 'init' task.
 4+ *
 5+ * This generated file contains a sample Kotlin application project to get you started.
 6+ * For more details on building Java & JVM projects, please refer to https://docs.gradle.org/8.14.3/userguide/building_java_projects.html in the Gradle documentation.
 7+ */
 8+
 9+plugins {
10+    // Apply the org.jetbrains.kotlin.jvm Plugin to add support for Kotlin.
11+    alias(libs.plugins.kotlin.jvm)
12+
13+    // Apply the application plugin to add support for building a CLI application in Java.
14+    application
15+}
16+
17+repositories {
18+    // Use Maven Central for resolving dependencies.
19+    mavenCentral()
20+}
21+
22+dependencies {
23+    // Use the Kotlin JUnit 5 integration.
24+    testImplementation("org.jetbrains.kotlin:kotlin-test-junit5")
25+
26+    // Use the JUnit 5 integration.
27+    testImplementation(libs.junit.jupiter.engine)
28+
29+    testRuntimeOnly("org.junit.platform:junit-platform-launcher")
30+
31+    // This dependency is used by the application.
32+    implementation(libs.guava)
33+}
34+
35+// Apply a specific Java toolchain to ease working on different environments.
36+java {
37+    toolchain {
38+        languageVersion = JavaLanguageVersion.of(21)
39+    }
40+}
41+
42+application {
43+    // Define the main class for the application.
44+    mainClass = "org.amadaluzia.RosettaCollatzKt"
45+}
46+
47+tasks.named<Test>("test") {
48+    // Use JUnit Platform for unit tests.
49+    useJUnitPlatform()
50+}
+32, -0
 1@@ -0,0 +1,32 @@
 2+/*
 3+ * This source file was generated by the Gradle 'init' task
 4+ */
 5+package org.amadaluzia
 6+
 7+fun collatz(x: Int): Int {
 8+        if (x % 2 == 0) {
 9+                return x / 2
10+        }
11+        return 3 * x + 1
12+}
13+
14+fun collatzSequence(x: Int): String  {
15+        if (x == 1) {
16+                return "1: 1"
17+        }
18+        var buf: String = String.format("%d: ", x)
19+        var index = x
20+        while (index > 1) {
21+                buf += String.format("%d, ", index)
22+                index = collatz(index)
23+        }
24+        buf += "1"
25+        return buf
26+}
27+
28+fun main() {
29+        for (i in 1..10_000) {
30+                val message = collatzSequence(i)
31+                println(message)
32+        }
33+}
+20, -0
 1@@ -0,0 +1,20 @@
 2+/*
 3+ * This source file was generated by the Gradle 'init' task
 4+ */
 5+package org.amadaluzia
 6+
 7+import kotlin.test.Test
 8+import kotlin.test.assertEquals
 9+
10+class RosettaCollatzTest {
11+    @Test fun collatzIsCorrect() {
12+        assertEquals(collatz(1), 4, "odd numbers should be multiplied by 3, add 1")
13+        assertEquals(collatz(2), 1, "even numbers should divide by zero")
14+    }
15+    @Test fun collatzSequenceIsCorrect() {
16+        assertEquals(collatzSequence(1), "1: 1", "this value would be returned if it's 1")
17+        assertEquals(collatzSequence(2), "2: 2, 1", "even numbers should be divided by 2")
18+        // the number jumped to 5 to make the test pass quicker (3 -> 10 -> 5)
19+        assertEquals(collatzSequence(5), "5: 5, 16, 8, 4, 2, 1", "odd numbers should be multiplied by 3, add 1")
20+    }
21+}
+5, -0
1@@ -0,0 +1,5 @@
2+# This file was generated by the Gradle 'init' task.
3+# https://docs.gradle.org/current/userguide/build_environment.html#sec:gradle_configuration_properties
4+
5+org.gradle.configuration-cache=true
6+
+13, -0
 1@@ -0,0 +1,13 @@
 2+# This file was generated by the Gradle 'init' task.
 3+# https://docs.gradle.org/current/userguide/platforms.html#sub::toml-dependencies-format
 4+
 5+[versions]
 6+guava = "33.4.5-jre"
 7+junit-jupiter-engine = "5.12.1"
 8+
 9+[libraries]
10+guava = { module = "com.google.guava:guava", version.ref = "guava" }
11+junit-jupiter-engine = { module = "org.junit.jupiter:junit-jupiter-engine", version.ref = "junit-jupiter-engine" }
12+
13+[plugins]
14+kotlin-jvm = { id = "org.jetbrains.kotlin.jvm", version = "2.1.20" }
+0, -0
+7, -0
1@@ -0,0 +1,7 @@
2+distributionBase=GRADLE_USER_HOME
3+distributionPath=wrapper/dists
4+distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
5+networkTimeout=10000
6+validateDistributionUrl=true
7+zipStoreBase=GRADLE_USER_HOME
8+zipStorePath=wrapper/dists
+251, -0
  1@@ -0,0 +1,251 @@
  2+#!/bin/sh
  3+
  4+#
  5+# Copyright © 2015-2021 the original authors.
  6+#
  7+# Licensed under the Apache License, Version 2.0 (the "License");
  8+# you may not use this file except in compliance with the License.
  9+# You may obtain a copy of the License at
 10+#
 11+#      https://www.apache.org/licenses/LICENSE-2.0
 12+#
 13+# Unless required by applicable law or agreed to in writing, software
 14+# distributed under the License is distributed on an "AS IS" BASIS,
 15+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 16+# See the License for the specific language governing permissions and
 17+# limitations under the License.
 18+#
 19+# SPDX-License-Identifier: Apache-2.0
 20+#
 21+
 22+##############################################################################
 23+#
 24+#   Gradle start up script for POSIX generated by Gradle.
 25+#
 26+#   Important for running:
 27+#
 28+#   (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is
 29+#       noncompliant, but you have some other compliant shell such as ksh or
 30+#       bash, then to run this script, type that shell name before the whole
 31+#       command line, like:
 32+#
 33+#           ksh Gradle
 34+#
 35+#       Busybox and similar reduced shells will NOT work, because this script
 36+#       requires all of these POSIX shell features:
 37+#         * functions;
 38+#         * expansions «$var», «${var}», «${var:-default}», «${var+SET}»,
 39+#           «${var#prefix}», «${var%suffix}», and «$( cmd )»;
 40+#         * compound commands having a testable exit status, especially «case»;
 41+#         * various built-in commands including «command», «set», and «ulimit».
 42+#
 43+#   Important for patching:
 44+#
 45+#   (2) This script targets any POSIX shell, so it avoids extensions provided
 46+#       by Bash, Ksh, etc; in particular arrays are avoided.
 47+#
 48+#       The "traditional" practice of packing multiple parameters into a
 49+#       space-separated string is a well documented source of bugs and security
 50+#       problems, so this is (mostly) avoided, by progressively accumulating
 51+#       options in "$@", and eventually passing that to Java.
 52+#
 53+#       Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS,
 54+#       and GRADLE_OPTS) rely on word-splitting, this is performed explicitly;
 55+#       see the in-line comments for details.
 56+#
 57+#       There are tweaks for specific operating systems such as AIX, CygWin,
 58+#       Darwin, MinGW, and NonStop.
 59+#
 60+#   (3) This script is generated from the Groovy template
 61+#       https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
 62+#       within the Gradle project.
 63+#
 64+#       You can find Gradle at https://github.com/gradle/gradle/.
 65+#
 66+##############################################################################
 67+
 68+# Attempt to set APP_HOME
 69+
 70+# Resolve links: $0 may be a link
 71+app_path=$0
 72+
 73+# Need this for daisy-chained symlinks.
 74+while
 75+    APP_HOME=${app_path%"${app_path##*/}"}  # leaves a trailing /; empty if no leading path
 76+    [ -h "$app_path" ]
 77+do
 78+    ls=$( ls -ld "$app_path" )
 79+    link=${ls#*' -> '}
 80+    case $link in             #(
 81+      /*)   app_path=$link ;; #(
 82+      *)    app_path=$APP_HOME$link ;;
 83+    esac
 84+done
 85+
 86+# This is normally unused
 87+# shellcheck disable=SC2034
 88+APP_BASE_NAME=${0##*/}
 89+# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
 90+APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit
 91+
 92+# Use the maximum available, or set MAX_FD != -1 to use that value.
 93+MAX_FD=maximum
 94+
 95+warn () {
 96+    echo "$*"
 97+} >&2
 98+
 99+die () {
100+    echo
101+    echo "$*"
102+    echo
103+    exit 1
104+} >&2
105+
106+# OS specific support (must be 'true' or 'false').
107+cygwin=false
108+msys=false
109+darwin=false
110+nonstop=false
111+case "$( uname )" in                #(
112+  CYGWIN* )         cygwin=true  ;; #(
113+  Darwin* )         darwin=true  ;; #(
114+  MSYS* | MINGW* )  msys=true    ;; #(
115+  NONSTOP* )        nonstop=true ;;
116+esac
117+
118+CLASSPATH="\\\"\\\""
119+
120+
121+# Determine the Java command to use to start the JVM.
122+if [ -n "$JAVA_HOME" ] ; then
123+    if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
124+        # IBM's JDK on AIX uses strange locations for the executables
125+        JAVACMD=$JAVA_HOME/jre/sh/java
126+    else
127+        JAVACMD=$JAVA_HOME/bin/java
128+    fi
129+    if [ ! -x "$JAVACMD" ] ; then
130+        die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
131+
132+Please set the JAVA_HOME variable in your environment to match the
133+location of your Java installation."
134+    fi
135+else
136+    JAVACMD=java
137+    if ! command -v java >/dev/null 2>&1
138+    then
139+        die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
140+
141+Please set the JAVA_HOME variable in your environment to match the
142+location of your Java installation."
143+    fi
144+fi
145+
146+# Increase the maximum file descriptors if we can.
147+if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
148+    case $MAX_FD in #(
149+      max*)
150+        # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
151+        # shellcheck disable=SC2039,SC3045
152+        MAX_FD=$( ulimit -H -n ) ||
153+            warn "Could not query maximum file descriptor limit"
154+    esac
155+    case $MAX_FD in  #(
156+      '' | soft) :;; #(
157+      *)
158+        # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
159+        # shellcheck disable=SC2039,SC3045
160+        ulimit -n "$MAX_FD" ||
161+            warn "Could not set maximum file descriptor limit to $MAX_FD"
162+    esac
163+fi
164+
165+# Collect all arguments for the java command, stacking in reverse order:
166+#   * args from the command line
167+#   * the main class name
168+#   * -classpath
169+#   * -D...appname settings
170+#   * --module-path (only if needed)
171+#   * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables.
172+
173+# For Cygwin or MSYS, switch paths to Windows format before running java
174+if "$cygwin" || "$msys" ; then
175+    APP_HOME=$( cygpath --path --mixed "$APP_HOME" )
176+    CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" )
177+
178+    JAVACMD=$( cygpath --unix "$JAVACMD" )
179+
180+    # Now convert the arguments - kludge to limit ourselves to /bin/sh
181+    for arg do
182+        if
183+            case $arg in                                #(
184+              -*)   false ;;                            # don't mess with options #(
185+              /?*)  t=${arg#/} t=/${t%%/*}              # looks like a POSIX filepath
186+                    [ -e "$t" ] ;;                      #(
187+              *)    false ;;
188+            esac
189+        then
190+            arg=$( cygpath --path --ignore --mixed "$arg" )
191+        fi
192+        # Roll the args list around exactly as many times as the number of
193+        # args, so each arg winds up back in the position where it started, but
194+        # possibly modified.
195+        #
196+        # NB: a `for` loop captures its iteration list before it begins, so
197+        # changing the positional parameters here affects neither the number of
198+        # iterations, nor the values presented in `arg`.
199+        shift                   # remove old arg
200+        set -- "$@" "$arg"      # push replacement arg
201+    done
202+fi
203+
204+
205+# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
206+DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'
207+
208+# Collect all arguments for the java command:
209+#   * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
210+#     and any embedded shellness will be escaped.
211+#   * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
212+#     treated as '${Hostname}' itself on the command line.
213+
214+set -- \
215+        "-Dorg.gradle.appname=$APP_BASE_NAME" \
216+        -classpath "$CLASSPATH" \
217+        -jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \
218+        "$@"
219+
220+# Stop when "xargs" is not available.
221+if ! command -v xargs >/dev/null 2>&1
222+then
223+    die "xargs is not available"
224+fi
225+
226+# Use "xargs" to parse quoted args.
227+#
228+# With -n1 it outputs one arg per line, with the quotes and backslashes removed.
229+#
230+# In Bash we could simply go:
231+#
232+#   readarray ARGS < <( xargs -n1 <<<"$var" ) &&
233+#   set -- "${ARGS[@]}" "$@"
234+#
235+# but POSIX shell has neither arrays nor command substitution, so instead we
236+# post-process each arg (as a line of input to sed) to backslash-escape any
237+# character that might be a shell metacharacter, then use eval to reverse
238+# that process (while maintaining the separation between arguments), and wrap
239+# the whole thing up as a single "set" statement.
240+#
241+# This will of course break if any of these variables contains a newline or
242+# an unmatched quote.
243+#
244+
245+eval "set -- $(
246+        printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" |
247+        xargs -n1 |
248+        sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' |
249+        tr '\n' ' '
250+    )" '"$@"'
251+
252+exec "$JAVACMD" "$@"
+94, -0
 1@@ -0,0 +1,94 @@
 2+@rem
 3+@rem Copyright 2015 the original author or authors.
 4+@rem
 5+@rem Licensed under the Apache License, Version 2.0 (the "License");
 6+@rem you may not use this file except in compliance with the License.
 7+@rem You may obtain a copy of the License at
 8+@rem
 9+@rem      https://www.apache.org/licenses/LICENSE-2.0
10+@rem
11+@rem Unless required by applicable law or agreed to in writing, software
12+@rem distributed under the License is distributed on an "AS IS" BASIS,
13+@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+@rem See the License for the specific language governing permissions and
15+@rem limitations under the License.
16+@rem
17+@rem SPDX-License-Identifier: Apache-2.0
18+@rem
19+
20+@if "%DEBUG%"=="" @echo off
21+@rem ##########################################################################
22+@rem
23+@rem  Gradle startup script for Windows
24+@rem
25+@rem ##########################################################################
26+
27+@rem Set local scope for the variables with windows NT shell
28+if "%OS%"=="Windows_NT" setlocal
29+
30+set DIRNAME=%~dp0
31+if "%DIRNAME%"=="" set DIRNAME=.
32+@rem This is normally unused
33+set APP_BASE_NAME=%~n0
34+set APP_HOME=%DIRNAME%
35+
36+@rem Resolve any "." and ".." in APP_HOME to make it shorter.
37+for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
38+
39+@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
40+set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
41+
42+@rem Find java.exe
43+if defined JAVA_HOME goto findJavaFromJavaHome
44+
45+set JAVA_EXE=java.exe
46+%JAVA_EXE% -version >NUL 2>&1
47+if %ERRORLEVEL% equ 0 goto execute
48+
49+echo. 1>&2
50+echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
51+echo. 1>&2
52+echo Please set the JAVA_HOME variable in your environment to match the 1>&2
53+echo location of your Java installation. 1>&2
54+
55+goto fail
56+
57+:findJavaFromJavaHome
58+set JAVA_HOME=%JAVA_HOME:"=%
59+set JAVA_EXE=%JAVA_HOME%/bin/java.exe
60+
61+if exist "%JAVA_EXE%" goto execute
62+
63+echo. 1>&2
64+echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
65+echo. 1>&2
66+echo Please set the JAVA_HOME variable in your environment to match the 1>&2
67+echo location of your Java installation. 1>&2
68+
69+goto fail
70+
71+:execute
72+@rem Setup the command line
73+
74+set CLASSPATH=
75+
76+
77+@rem Execute Gradle
78+"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %*
79+
80+:end
81+@rem End local scope for the variables with windows NT shell
82+if %ERRORLEVEL% equ 0 goto mainEnd
83+
84+:fail
85+rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
86+rem the _cmd.exe /c_ return code!
87+set EXIT_CODE=%ERRORLEVEL%
88+if %EXIT_CODE% equ 0 set EXIT_CODE=1
89+if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE%
90+exit /b %EXIT_CODE%
91+
92+:mainEnd
93+if "%OS%"=="Windows_NT" endlocal
94+
95+:omega
+14, -0
 1@@ -0,0 +1,14 @@
 2+/*
 3+ * This file was generated by the Gradle 'init' task.
 4+ *
 5+ * The settings file is used to specify which projects to include in your build.
 6+ * For more detailed information on multi-project builds, please refer to https://docs.gradle.org/8.14.3/userguide/multi_project_builds.html in the Gradle documentation.
 7+ */
 8+
 9+plugins {
10+    // Apply the foojay-resolver plugin to allow automatic download of JDKs
11+    id("org.gradle.toolchains.foojay-resolver-convention") version "0.10.0"
12+}
13+
14+rootProject.name = "rosetta-collatz"
15+include("app")