-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
LIT-16
- Loading branch information
Showing
70 changed files
with
12,145 additions
and
1,023 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"presets": ["env"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Unifying editor configurations for all developers: | ||
# For details see http://editorconfig.org/ | ||
|
||
root = true | ||
|
||
[*] | ||
end_of_line = lf | ||
indent_size = 2 | ||
indent_style = space | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
{ | ||
"extends": "airbnb-base", | ||
"env": { | ||
"mocha": true | ||
}, | ||
"globals": { | ||
"artifacts": true, | ||
"assert": true, | ||
"beforeEach": true, | ||
"contract": true, | ||
"describe": true, | ||
"it": true, | ||
"web3": true | ||
}, | ||
"rules": { | ||
"no-console": "off", | ||
"prefer-destructuring": ["error", { | ||
"VariableDeclarator": { | ||
"array": true, | ||
"object": true | ||
}, | ||
"AssignmentExpression": { | ||
"array": false, // this will allow for: var bar = foo[0] <- access array with index | ||
"object": true | ||
} | ||
}, { | ||
"enforceForRenamedProperties": false | ||
}] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
.idea/ | ||
|
||
build/ | ||
|
||
node_modules/ | ||
package-lock.json | ||
coverage/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
module.exports = { | ||
copyPackages: ['openzeppelin-solidity', 'zeppelin-solidity', 'pokedex', 'token-sale-contracts'], | ||
port: 8545, | ||
norpc: false, | ||
compileCommand: 'truffle compile --all', | ||
testCommand: 'truffle test --network coverage', | ||
skipFiles: ['lib/ECRecovery.sol', 'lib/RLP.sol'] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
node_modules | ||
helpers | ||
migrations | ||
test | ||
contracts/Migrations.sol | ||
coverage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"extends": "solium:recommended", | ||
"plugins": [ | ||
"security" | ||
], | ||
"rules": { | ||
"quotes": [ | ||
"error", | ||
"double" | ||
], | ||
"indentation": [ | ||
"error", | ||
2 | ||
], | ||
"security/no-inline-assembly": 0, | ||
"security/no-assign-params": 0, | ||
"security/no-block-members": [0, ["timestamp"]] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# Changelog | ||
All notable changes to this project will be documented in this file. | ||
|
||
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) | ||
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). | ||
|
||
## [0.1.0] - 2018-10-31 | ||
|
||
Plasma Cash: | ||
- Ethereum smart contract for on-chain plasma cash | ||
- Plasma participants: users, operator |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
pragma solidity 0.4.24; | ||
|
||
import "openzeppelin-solidity/contracts/ownership/Ownable.sol"; | ||
|
||
contract Operable is Ownable { | ||
|
||
mapping(address => bool) public operators; | ||
|
||
event LogSetOperator(address executor, address operator, bool status); | ||
|
||
modifier onlyOperator() { | ||
require(operators[msg.sender], "you are not the operator"); | ||
_; | ||
} | ||
|
||
function setOperator(address _operator, bool _status) | ||
public | ||
onlyOwner | ||
returns (bool) { | ||
operators[_operator] = _status; | ||
emit LogSetOperator(msg.sender, _operator, _status); | ||
return true; | ||
} | ||
|
||
} |
Oops, something went wrong.