Skip to content

Instantly share code, notes, and snippets.

@thomasjslone
thomasjslone / rubin_installer-v1.0.14.rb
Last active December 28, 2024 04:30
install component and unpackaged_installer redone
## installer version 1.5
## Run this script to install Rubin System.
## Rubin System is a ruby app runtime environment. Built for Mingw Ruby and Windows.
## !! WARNING !! If you did not download this script from @thomasjslone's github, DO NOT RUN IT!
##
##init
$version='1.0.14' ; launch_directory=Dir.getwd; maindatasep = "#1#::#"+"1#::#4#"+"#9#::#1#::#2#" ; filenamesep = "#1#::#"+"3#::#1#"+"#4#::#1#::#8#" ; filesep = "#1#::#"+"1#::#0#"+"#3#::#7#::#5#" ; index_sep = "#1#::#"+"4#::#4#"+"#5#::#1#::#9#"
##checks
if defined?(SYSTEM) == "constant"
@thomasjslone
thomasjslone / rubin_installer-v1.0.13.rb
Created December 26, 2024 18:48
minor bug fixes to controller and install process
## installer version 1.4
## no package included, paste one into the last line of the file, you can generate one using install.build_package
## RubinSystem is a ruby app runtime environment. Multi-Instance, bot controller on Mingw Windows Ruby
## ## !! WARNING !! If you did not download this script from github or the official website, DO NOT RUN IT!
## Run this script to install Rubin System in either the current directory or one you enter.
##
## installer version 1.3
## RubinSystem is a ruby app runtime environment. Multi-Instance, bot controller on Mingw Windows Ruby
## ## !! WARNING !! If you did not download this script from github or the official website, DO NOT RUN IT!
## Run this script to install Rubin System in either the current directory or one you enter.
##
#begin
unless defined?(VERSION); VERSION = "1.0.12"; end
launch_directory=Dir.getwd; launch_time=Time.now
@thomasjslone
thomasjslone / build_locker_script.rb
Last active November 25, 2024 23:18
build a script that encodes/decodes one file automatically, to keep it from people who have access to your pc.
## locker builder ver 1.2, thomasjslone 2024-11-25
## Instructions:
##
## Run build.rb to create a ruby script you can run to encode/decode your files.
## This is NOT secure and simply to prevent friends and family or any one with access to your
## pc from reading the file. This file has basic measures to prevent ammeture scripters from
## decoding however anyone with actual programming experience can still reverse engineer and
## access your data. THIS IS NOT ENCRYPTION and not at all secure.
##
## The script created only needs to be stored in the same directory as its target file if you
@thomasjslone
thomasjslone / build_file_locker.rb
Created November 25, 2024 04:08
file locker v1.2 obfacation partialy added, not great but enough to confuse the hell out of an intermediate scripter
## locker builder ver 1.1, thomasjslone 2024-11-24
## Instructions:
##
## Locker is intended for use on windows, with ruby properly installed allowing you to double click the script to run it.
## Locker is NOT encryption and will not stop experienced programmers from decoding your information.
## Locker is intended to obfascate your files from people who have access to your computer however do not have advanced programming skills.
##
## To begin, run this file('build.rb')
## You will be asked to select a directory and enter a file name.
## The ruby script generated can be stored with or away from the target file you want to protect, the locker can also have a set password.
@thomasjslone
thomasjslone / build_file_locker.rb
Last active November 25, 2024 01:51
keep text files hidden from your family (not encryption! only secure against non programmer people)
## locker builder ver 1.0, thomasjslone 2024-11-24
## Instructions:
##
## Locker is intended for use on windows, with ruby properly installed allowing you to double click the script to run it.
## Locker is NOT encryption and will not stop experienced programmers from decoding your information.
## Locker is intended to obfascate your files from people who have access to your computer.
##
## To begin, run this file('build.rb')
## You will be asked to select a directory and enter a file name.
## The ruby script generated can be stored with or away from the target file you want to protect, the locker can also have a set password.
@thomasjslone
thomasjslone / snippet.rb
Created November 16, 2024 04:27
rubin core install location changed handler code, older code witha snippet that allows linux to have disks named rubin or multiple dirs named rubin in the path
##about this code
## in windows a mounted disks path is a drive letter C:/ E:/ F:/ ect.
## however in linux the path is the name of the disk, if a disk is named "rubin" the launch
## will fail because it expects the name rubin to only be in a path once
##this error will also occur if the install is nested in multiple directories named 'rubin'
## this code is outdated and may not be needed anymore
@thomasjslone
thomasjslone / launch.rb
Last active November 16, 2024 03:55
rubin launcher finnaly serves a purpose, link to entry point and configure runtime perams
## launch.rb ; file ver 1.0 for rubin 1.0.4 and up ; Rubin system default launcher. Thomas J Slone 2024 11 3
##big news! this file is now a proper launcher, rubin can still be started by loading the system file in an interpreter from the home directory
## however this launcher will perform startup checks and configure the interpreter for various runtime modes (such as debug, windowless, server, low memory)
##this file is the entry point for rubin system, it can be ran a few ways, explorer.exe can have it clicked, cmd.exe can tell ruby.exe to run this file, or an already running
##interpreter can load this file, this file cannot be evaled by a client/console outside of the install directory
##prepare args to be passed if there are any
if ARGV.length > 0 ; $argv = ARGV ; $argv.insert(0,"-") ; $argv = $argv.join(" ")
else ; $argv = ""
@thomasjslone
thomasjslone / dictionarydatabank.rb
Last active July 25, 2024 16:33
redid my old dictionary database with efficiency in mind
#@# dictionarydatabank.rb - version 1.0 tested on 2024.07.26 - thomas j slone
## a sort of database, designed for dictionary builders, store billions of words by dividing massive arrays into bank files of limited size.
## final todos
##
## enforce add string size limit
## add a config file for banks so when reloading bank and string sizes dont have to be given only when making a bank for the first time
## add methods for geting and setting size limits and possibly renaming bank though that literally requires moving the entire directory to rename it
@thomasjslone
thomasjslone / gpt spiral ascii
Last active January 21, 2025 18:13
gpt actually did ok, wonder where it stole this code from
def draw_spiral(size)
grid = Array.new(size * 2 + 1) { Array.new(size * 2 + 1, ' ') }
x, y = size, size
direction = 0 # 0: right, 1: down, 2: left, 3: up
step = 1
(size * size).times do |i|
grid[y][x] = '*'
case direction