{"id":18885423,"url":"https://github.com/atechguide/chainlist","last_synced_at":"2026-05-08T13:09:14.049Z","repository":{"id":127851827,"uuid":"123589521","full_name":"aTechGuide/Chainlist","owner":"aTechGuide","description":"Emulation of Craiglist as DAPP on etherium blockchain","archived":false,"fork":false,"pushed_at":"2018-06-03T08:37:25.000Z","size":398,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-12-31T04:41:58.348Z","etag":null,"topics":["blockchain","ethereum","project","solidity"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aTechGuide.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-03-02T14:32:09.000Z","updated_at":"2021-03-12T15:38:25.000Z","dependencies_parsed_at":null,"dependency_job_id":"9e8ab902-6bae-4bcc-bd60-b33497b77029","html_url":"https://github.com/aTechGuide/Chainlist","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aTechGuide%2FChainlist","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aTechGuide%2FChainlist/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aTechGuide%2FChainlist/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aTechGuide%2FChainlist/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aTechGuide","download_url":"https://codeload.github.com/aTechGuide/Chainlist/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239858820,"owners_count":19708856,"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":["blockchain","ethereum","project","solidity"],"created_at":"2024-11-08T07:18:35.199Z","updated_at":"2026-02-23T06:30:18.671Z","avatar_url":"https://github.com/aTechGuide.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Chainlist DAPP\n\nNode JS DApp emulating craiglist on Ethereum block chain. This DAPP uses Truffle, Metamask.\n\n## Live Preview\n[ChailList Web Console](https://kamranali.in/Chainlist/)\n\n# Developer Zone\n## Truffle Commands\n\n**Project Initialization**\n``` unbox chainskills/chainskills-box ```\n\n**To compile contract**\n``` truffle migrate --compile-all --reset --network ganache ```\n\n**To connect to console**\n``` truffle console --network ganache ```\n\n**To run test**\n``` truffle test --network ganache ```\n\n**To interact with contract**\n```\nChainList.deployed().then(function(instance) {app=instance;})\napp.getArticlesForSale()\napp.getNumberOfArticles()\napp.sellArticle(\"Article 1 \", \"Description of Article 1\", web3.toWei(10, \"ether\"), {from: web3.eth.accounts[1]})\napp.buyArticle(1, {from: web3.eth.accounts[3], value: web3.toWei(10, \"ether\")})\napp.kill({from: web3.eth.accounts[0]})\n```\n\n**To check balance**\n``` web3.fromWei(web3.eth.getBalance(web3.eth.accounts[0]), \"ether\").toNumber() ```\n\n**Events**\n``` \nvar sellEvent = app.LogSellArticle({}, {fromBlock: 0, toBlock:'latest'}).watch(function(error,event) {console.log(event);}) \nsellEvent.stopWatching() // To stop watching event\nvar sellEvent = app.LogSellArticle({}, {}).watch(function(error,event) {console.log(event);}) // Default for both parameters (fromBlock and toBlock) is latest\nvar buyEvent = app.LogBuyArticle({_seller: web3.eth.accounts[1]}, {}).watch(function(error,event) {console.log(event);})\nvar buyEvent = app.LogBuyArticle({}, {}).watch(function(error,event) {console.log(event);})\n```\n\n## DApp Commands\n**Run DAPP** ``` npm run dev ```\n\n## Web3 Commands\n```\nweb3.fromWei(web3.eth.getBalance(web3.eth.accounts[0]), \"ether\").toNumber() // To get account balance\nweb3.eth.coinbase // To get Primary account\nweb3.eth.sendTransaction({from: web3.eth.accounts[0], to: web3.eth.accounts[1], value: web3.toWei(5, \"ether\")})\n```\n## Notes\n- *Migrations.sol*: keeps track of which migration scripts have already been executed on each block chain instance that we are going to work with\n- *Initial_migration*: deploys the migration contract that truffle interacts with to determine which contract still has to be deployed to blockchian network\n- By default 0th address is unlocked in our startnode.sh file.\n- If we specify from Address in chainskills network in truffle.js and put 1th address in from node.e.g. ``` from: '0x849724b2c67f00c52c2e6283e5b8a7c30a46cfab' // Second address on our private node CMD[web3.eth.accounts] ``` we need to unlock it first befor compiling our contract.\n- To unlock 1st address, ``` truffle console --network chainskills // open console\n  web3.personal.unlockAccount(web3.eth.accounts[1], \"pass1234\", 600) // unlocking account for 10 mins ```\n\n## Important Online Resources\n- [Hex to string Converter](https://codebeautify.org/hex-string-converter)\n- [Gas Station](https://ethgasstation.info/)\n- [Currency Converter](https://converter.murkin.me/)\n- [Online converter to ops code](https://etherscan.io/opcode-tool)\n- [Live Ether Scan](https://etherscan.io/)\n- [Contract Inheritance](http://solidity.readthedocs.io/en/latest/contracts.html#inheritance)\n- [Rinkeby Faucet](https://www.rinkeby.io/#faucet)\n- [Rinkeby Ether Scan](https://rinkeby.etherscan.io/)\n- [Live Ether Scan](https://etherscan.io/)\n- Course [link](https://www.udemy.com/getting-started-with-ethereum-solidity-development/)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatechguide%2Fchainlist","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fatechguide%2Fchainlist","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fatechguide%2Fchainlist/lists"}