rustby 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: b1d8f48cb3ad27d5f5d08d7c92317bf79011cb06acd57a51ae5d64d998a6f9a8
4
+ data.tar.gz: f514497b0aed89a875f82cc9ddd4de6f5220d74695f7c8e888a12c9ab3bb5aec
5
+ SHA512:
6
+ metadata.gz: 14ec3fae8aa5983ec12fc86f003652f1a6fe2622cee5cec023d2cb71f51fb35bde1c8c39aa33abc55b8ccfc0784330125760fe7203942ec9874b63b537f1b26e
7
+ data.tar.gz: 0d6d6db80c9ef44a398d3a1e2e3263fa8d3fa62c9ef2363e5705e33715af38004602ba23eb9e5273ad74a4272b1b18935788dd2baf930a8e3b9ad779b88119e1
data/.gitignore ADDED
@@ -0,0 +1,8 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /_yardoc/
4
+ /coverage/
5
+ /doc/
6
+ /pkg/
7
+ /spec/reports/
8
+ /tmp/
data/Gemfile ADDED
@@ -0,0 +1,6 @@
1
+ # frozen_string_literal: true
2
+
3
+ source 'https://rubygems.org'
4
+
5
+ # Specify your gem's dependencies in rustby.gemspec
6
+ gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,17 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ rustby (0.1.0)
5
+
6
+ GEM
7
+ remote: https://rubygems.org/
8
+ specs:
9
+
10
+ PLATFORMS
11
+ x86_64-linux
12
+
13
+ DEPENDENCIES
14
+ rustby!
15
+
16
+ BUNDLED WITH
17
+ 2.2.22
data/README.md ADDED
@@ -0,0 +1,35 @@
1
+ # Rustby
2
+
3
+ Welcome to your new gem! In this directory, you'll find the files you need to be able to package up your Ruby library into a gem. Put your Ruby code in the file `lib/rustby`. To experiment with that code, run `bin/console` for an interactive prompt.
4
+
5
+ TODO: Delete this and the text above, and describe your gem
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's Gemfile:
10
+
11
+ ```ruby
12
+ gem 'rustby'
13
+ ```
14
+
15
+ And then execute:
16
+
17
+ $ bundle install
18
+
19
+ Or install it yourself as:
20
+
21
+ $ gem install rustby
22
+
23
+ ## Usage
24
+
25
+ TODO: Write usage instructions here
26
+
27
+ ## Development
28
+
29
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake ` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
30
+
31
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and the created tag, and push the `.gem` file to [rubygems.org](https://rubygems.org).
32
+
33
+ ## Contributing
34
+
35
+ Bug reports and pull requests are welcome on GitHub at https://github.com/[USERNAME]/rustby.
data/Rakefile ADDED
@@ -0,0 +1,9 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'bundler/gem_tasks'
4
+ task default: %i[]
5
+ require 'rake/extensiontask'
6
+
7
+ Rake::ExtensionTask.new('rustby') do |ext|
8
+ ext.lib_dir = 'ext'
9
+ end
data/bin/console ADDED
@@ -0,0 +1,15 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ require 'bundler/setup'
5
+ require 'rustby'
6
+
7
+ # You can add fixtures and/or initialization code here to make experimenting
8
+ # with your gem easier. You can also use a different console, if you like.
9
+
10
+ # (If you use this, don't forget to add pry to your Gemfile!)
11
+ # require "pry"
12
+ # Pry.start
13
+
14
+ require 'irb'
15
+ IRB.start(__FILE__)
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1 @@
1
+ /target
@@ -0,0 +1,7 @@
1
+ # This file is automatically @generated by Cargo.
2
+ # It is not intended for manual editing.
3
+ version = 3
4
+
5
+ [[package]]
6
+ name = "rustby"
7
+ version = "0.1.0"
@@ -0,0 +1,11 @@
1
+ [package]
2
+ name = "rustby"
3
+ version = "0.1.0"
4
+ edition = "2021"
5
+
6
+ # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
7
+
8
+ [lib]
9
+ crate-type = ["cdylib"]
10
+
11
+ [dependencies]
@@ -0,0 +1,7 @@
1
+ all: target/release/librustby.so ../rustby.so
2
+
3
+ target/release/librustby.so: src/lib.rs
4
+ cargo build --release
5
+
6
+ ../rustby.so: target/release/librustby.so
7
+ cp $^ $@
@@ -0,0 +1 @@
1
+ # frozen_string_literal: true
@@ -0,0 +1,4 @@
1
+ #[no_mangle]
2
+ pub extern "C" fn Init_rustby() {
3
+ println!("Hello, world!");
4
+ }
data/ext/rustby.so ADDED
Binary file
@@ -0,0 +1,5 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Rustby
4
+ VERSION = '0.1.0'
5
+ end
data/lib/rustby.rb ADDED
@@ -0,0 +1,9 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative 'rustby/version'
4
+ require 'rustby.so'
5
+
6
+ module Rustby
7
+ class Error < StandardError; end
8
+ # Your code goes here...
9
+ end
data/rustby.gemspec ADDED
@@ -0,0 +1,25 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative 'lib/rustby/version'
4
+
5
+ Gem::Specification.new do |spec|
6
+ spec.name = 'rustby'
7
+ spec.version = Rustby::VERSION
8
+ spec.authors = ['Murata Mitsuharu']
9
+ spec.email = ['hikari.photon+dev@gmail.com']
10
+
11
+ spec.summary = 'Rust test'
12
+ spec.description = 'Rust test'
13
+ spec.homepage = 'https://github.com/himeyama/rustby'
14
+ spec.required_ruby_version = '>= 2.5.0'
15
+ spec.license = 'MIT'
16
+
17
+ spec.metadata['homepage_uri'] = spec.homepage
18
+
19
+ spec.files = Dir.chdir(File.expand_path(__dir__)) do
20
+ `git ls-files -z`.split("\x0").reject { |f| f.match(%r{\A(?:test|spec|features)/}) }
21
+ end
22
+ spec.bindir = 'exe'
23
+ spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
24
+ spec.require_paths = %w[lib ext]
25
+ end
metadata ADDED
@@ -0,0 +1,62 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: rustby
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Murata Mitsuharu
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2021-11-14 00:00:00.000000000 Z
12
+ dependencies: []
13
+ description: Rust test
14
+ email:
15
+ - hikari.photon+dev@gmail.com
16
+ executables: []
17
+ extensions: []
18
+ extra_rdoc_files: []
19
+ files:
20
+ - ".gitignore"
21
+ - Gemfile
22
+ - Gemfile.lock
23
+ - README.md
24
+ - Rakefile
25
+ - bin/console
26
+ - bin/setup
27
+ - ext/rustby.so
28
+ - ext/rustby/.gitignore
29
+ - ext/rustby/Cargo.lock
30
+ - ext/rustby/Cargo.toml
31
+ - ext/rustby/Makefile
32
+ - ext/rustby/extconf.rb
33
+ - ext/rustby/src/lib.rs
34
+ - lib/rustby.rb
35
+ - lib/rustby/version.rb
36
+ - rustby.gemspec
37
+ homepage: https://github.com/himeyama/rustby
38
+ licenses:
39
+ - MIT
40
+ metadata:
41
+ homepage_uri: https://github.com/himeyama/rustby
42
+ post_install_message:
43
+ rdoc_options: []
44
+ require_paths:
45
+ - lib
46
+ - ext
47
+ required_ruby_version: !ruby/object:Gem::Requirement
48
+ requirements:
49
+ - - ">="
50
+ - !ruby/object:Gem::Version
51
+ version: 2.5.0
52
+ required_rubygems_version: !ruby/object:Gem::Requirement
53
+ requirements:
54
+ - - ">="
55
+ - !ruby/object:Gem::Version
56
+ version: '0'
57
+ requirements: []
58
+ rubygems_version: 3.2.22
59
+ signing_key:
60
+ specification_version: 4
61
+ summary: Rust test
62
+ test_files: []