Skip to content
This repository has been archived by the owner on Sep 13, 2022. It is now read-only.

Commit

Permalink
feat: reference ckb-ruby-scripts as submodule scripts/ and replace co…
Browse files Browse the repository at this point in the history
…ntracts/ with it
  • Loading branch information
ashchan committed Jan 17, 2019
1 parent f9152ae commit c9dad12
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 6 deletions.
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "scripts"]
path = scripts
url = https://github.com/nervosnetwork/ckb-ruby-scripts.git
10 changes: 5 additions & 5 deletions lib/ckb/udt_wallet.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
require "securerandom"

module Ckb
UNLOCK_SCRIPT = File.read(File.expand_path("../../../contracts/udt/unlock.rb", __FILE__))
UNLOCK_SINGLE_CELL_SCRIPT = File.read(File.expand_path("../../../contracts/udt/unlock_single_cell.rb", __FILE__))
CONTRACT_SCRIPT = File.read(File.expand_path("../../../contracts/udt/contract.rb", __FILE__))
FIXED_AMOUNT_GENESIS_UNLOCK_SCRIPT = File.read(File.expand_path("../../../contracts/fixed_amount_udt/genesis_unlock.rb", __FILE__))
FIXED_AMOUNT_CONTRACT_SCRIPT = File.read(File.expand_path("../../../contracts/fixed_amount_udt/contract.rb", __FILE__))
UNLOCK_SCRIPT = File.read(File.expand_path("../../../scripts/udt/unlock.rb", __FILE__))
UNLOCK_SINGLE_CELL_SCRIPT = File.read(File.expand_path("../../../scripts/udt/unlock_single_cell.rb", __FILE__))
CONTRACT_SCRIPT = File.read(File.expand_path("../../../scripts/udt/contract.rb", __FILE__))
FIXED_AMOUNT_GENESIS_UNLOCK_SCRIPT = File.read(File.expand_path("../../../scripts/fixed_amount_udt/genesis_unlock.rb", __FILE__))
FIXED_AMOUNT_CONTRACT_SCRIPT = File.read(File.expand_path("../../../scripts/fixed_amount_udt/contract.rb", __FILE__))

class TokenInfo
attr_reader :api
Expand Down
2 changes: 1 addition & 1 deletion lib/ckb/wallet.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
require "securerandom"

module Ckb
VERIFY_SCRIPT = File.read(File.expand_path("../../../contracts/bitcoin_unlock.rb", __FILE__))
VERIFY_SCRIPT = File.read(File.expand_path("../../../scripts/bitcoin_unlock.rb", __FILE__))

class Wallet
attr_reader :api
Expand Down
1 change: 1 addition & 0 deletions scripts
Submodule scripts added at 7758fb

0 comments on commit c9dad12

Please sign in to comment.