{"id":13484242,"url":"https://github.com/ruboto/ruboto","last_synced_at":"2025-10-03T14:54:26.947Z","repository":{"id":947725,"uuid":"726541","full_name":"ruboto/ruboto","owner":"ruboto","description":"A platform for developing apps using JRuby on Android.","archived":false,"fork":false,"pushed_at":"2023-05-15T11:51:06.000Z","size":117695,"stargazers_count":2032,"open_issues_count":80,"forks_count":158,"subscribers_count":99,"default_branch":"master","last_synced_at":"2025-05-11T13:08:28.661Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://ruboto.org/","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ruboto.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2010-06-17T19:20:59.000Z","updated_at":"2025-05-04T14:00:38.000Z","dependencies_parsed_at":"2023-07-06T19:46:55.576Z","dependency_job_id":null,"html_url":"https://github.com/ruboto/ruboto","commit_stats":{"total_commits":2182,"total_committers":40,"mean_commits":54.55,"dds":"0.23006416131989005","last_synced_commit":"37af4619d5281e50e1be3687b32c3f60a965e00c"},"previous_names":[],"tags_count":82,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ruboto%2Fruboto","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ruboto%2Fruboto/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ruboto%2Fruboto/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ruboto%2Fruboto/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ruboto","download_url":"https://codeload.github.com/ruboto/ruboto/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254101615,"owners_count":22014909,"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","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":[],"created_at":"2024-07-31T17:01:21.258Z","updated_at":"2025-10-03T14:54:21.364Z","avatar_url":"https://github.com/ruboto.png","language":"Ruby","funding_links":[],"categories":["Mobile Development","Ruby"],"sub_categories":[],"readme":"# Ruboto 2\n\nRuboto 2 is a redesign based on an [Android Studio](https://developer.android.com/studio/) workflow.\nThis means that the JRuby and Ruboto components will integrate into the standard gradle tooling used by\nregular Android Studio projects.\n\n## Starting a new Ruboto project\n\n* Download and install [Android studio](https://developer.android.com/studio/).\n\n* Choose \"Create New Project\" in the startup screen.\n  * Choose \"Phone and Tablet\" and \"No Activity\" for the project template.\n  * Choose \"Java\" for your language and \"Minimum SDK\" should be \"**API 27: Android 8.1 (Oreo)**\" or higher.\n\n* Add a **jcenter** to the `dependencyResolutionManagement/repositories` section of your `settings.gradle` file:\n  ```groovy\n  dependencyResolutionManagement {\n      ...\n      repositories {\n          ...\n          jcenter()\n      }\n  }\n  ```\n\n* Add the these dependencies to your `app/build.gradle` file:\n  ```groovy\n  dependencies {\n    ...\n    implementation fileTree(dir: 'libs', include: ['*.jar'])\n    implementation 'com.linkedin.dexmaker:dexmaker:2.19.1'\n    implementation 'me.qmx.jitescript:jitescript:0.4.1'\n    implementation 'com.jakewharton.android.repackaged:dalvik-dx:7.1.0_r7'\n  }\n  ```\n\n* Add `gems.rb` file:\n  ```ruby\n  source 'https://rubygems.org/'\n\n  gem 'ruboto', '~\u003e2.0.dev', git: 'https://github.com/ruboto/ruboto.git'\n  ```\n\n* Ensure you are using JRuby on the command line\n\n  Create a `.ruby-version` file:\n  ```text\n    jruby\n  ```\n\n* Initialize Ruboto:\n  ```shell\n  jruby -S bundle\n  jruby -S bundle exec ruboto init\n  ```\n\n  This will copy the core files to your project.\n\n\n* Add `app/gems.rb`\n  ```ruby\n  source 'https://rubygems.org/'\n\n  gem 'activerecord', '~\u003e7.0'\n  gem 'activerecord-jdbc-adapter', '~\u003e70.1'\n  gem 'sqldroid', '~\u003e1.0'\n  ```\n\n* Add `app/update_jruby_jar.sh`:\n  ```shell\n  #!/usr/bin/env bash\n  set -e\n\n  VERSION=\"9.4.2.0\"\n  FULL_VERSION=\"${VERSION}\"\n  # FULL_VERSION=\"${VERSION}-SNAPSHOT\" # Uncomment to use a local snapshot\n  # FULL_VERSION=\"${VERSION}-20190822.050313-17\" # Uncomment to use a remote snapshot\n  JAR_FILE=\"jruby-complete-${FULL_VERSION}.jar\"\n  DOWNLOAD_DIR=\"$HOME/Downloads\"\n  DOWNLOADED_JAR=\"${DOWNLOAD_DIR}/${JAR_FILE}\"\n  SCRIPT_DIR=$( cd -- \"$( dirname -- \"${BASH_SOURCE[0]}\" )\" \u0026\u003e /dev/null \u0026\u0026 pwd )\n\n  cd $SCRIPT_DIR\n\n  [ ! -d $HOME/Downloads ] \u0026\u0026 mkdir $HOME/Downloads  # Create the directory if we don't find it\n  [ ! -d ./libs ] \u0026\u0026 mkdir ./libs                    # Create the directory if we don't find it\n\n  cd libs\n  rm -f bcpkix-jdk15on-*.jar bcprov-jdk15on-*.jar bctls-jdk15on-*.jar cparse-jruby.jar generator.jar jline-*.jar jopenssl.jar jruby-complete-*.jar parser.jar psych.jar readline.jar snakeyaml-*.jar\n\n  if test -f \"${DOWNLOADED_JAR}\"; then\n    echo \"Found downloaded JAR\"\n  else\n    echo No \"${DOWNLOADED_JAR}\" - Downloading.\n    curl \"https://oss.sonatype.org/service/local/repositories/releases/content/org/jruby/jruby-complete/${VERSION}/jruby-complete-${VERSION}.jar\" -o \"${DOWNLOADED_JAR}\"\n  fi\n  cp ${DOWNLOADED_JAR} .\n\n  unzip -o -j ${JAR_FILE} '*.jar'\n\n  # FIXME(uwe): Why do we delete these files?\n  zip generator.jar -d json/ext/ByteListTranscoder.class\n  zip generator.jar -d json/ext/OptionsReader.class\n  zip generator.jar -d json/ext/Utils.class\n  zip generator.jar -d json/ext/RuntimeInfo.class\n\n  cd - \u003e/dev/null\n\n  cd src/main/java\n  find * -type f | grep \"org/jruby/\" | sed -e 's/\\.java//g' | sort \u003e ../../../overridden_classes.txt\n  cd - \u003e/dev/null\n\n  while read p; do\n    unzip -Z1 libs/${JAR_FILE} | grep \"$p\\\\.class\" \u003e classes.txt\n    unzip -Z1 libs/${JAR_FILE} | egrep \"$p(\\\\\\$[^$]+)*\\\\.class\" \u003e\u003e classes.txt\n    if [[ -s classes.txt ]] ; then\n      zip -d -@ libs/${JAR_FILE} \u003cclasses.txt\n      if [[ ! \"$?\" == \"0\" ]] ; then\n        zip -d libs/${JAR_FILE} \"$p\\\\.class\"\n      fi\n    fi\n    rm classes.txt\n  done \u003c overridden_classes.txt\n\n  rm overridden_classes.txt\n  \n  cd libs\n  rm -f digest.jar\n  cd - \u003e/dev/null\n  ```\n\n* Make `app/update_jruby_jar.sh` executable:\n  ```shell\n    chmod u+x app/update_jruby_jar.sh\n  ```\n\n* Generate `jruby.jar`:\n  ```shell\n    app/update_jruby_jar.sh\n  ```\n\n* Generate the startup activity:\n  ```shell\n    bundle exec ruboto gen class Activity --name StartupActivity\n  ```\n\n* Add the startup activity intent filter to the new activity tag in `app/src/main/AndroidManifest.xml`:\n  ```xml\n  \u003cactivity android:name='StartupActivity' android:exported=\"true\"\u003e\n      \u003cintent-filter\u003e\n          \u003caction android:name=\"android.intent.action.MAIN\" /\u003e\n          \u003ccategory android:name=\"android.intent.category.LAUNCHER\" /\u003e\n          \u003caction android:name=\"android.intent.action.VIEW\" /\u003e\n      \u003c/intent-filter\u003e\n  \u003c/activity\u003e\n  ```\n\n* Declare the Ruboto components and SplashActivity in `app/src/main/AndroidManifest.xml`\n  ```xml\n  \u003cactivity android:name='org.ruboto.RubotoActivity' /\u003e\n  \u003cactivity android:name='org.ruboto.RubotoDialog' android:theme='@android:style/Theme.Dialog' /\u003e\n  \u003cservice\n      android:name='org.ruboto.RubotoService'\n      android:exported='false' /\u003e\n  \u003cactivity\n      android:name='org.ruboto.SplashActivity'\n      android:configChanges='orientation|screenSize'\n      android:exported='false'\n      android:noHistory='true' /\u003e\n  ```\n\n  **Rember to sync the gradle config after the changes.**\n\n \n* Start your app!\n\n## Updating app gems\n\nUpdate your `app/gems.rb` (or `app/Gemfile`) and run\n  ```shell\n  bundle exec rake bundle\n  ```\n\n## Adding Ruboto to an existing Android Studio project\n\nHOWTO missing.  Pull requests welcome!\n\n# Ruboto 1.x\n\nLooking for Ruboto 1.x?  Switch to the [ruboto_1.x](https://github.com/ruboto/ruboto/tree/ruboto_1.x) branch.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fruboto%2Fruboto","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fruboto%2Fruboto","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fruboto%2Fruboto/lists"}