Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: move src to src dir #10

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@
"main": "index.js",
"scripts": {
"clean": "rm -rf dist/*",
"build": "parcel build index.html --public-url '.'",
"dev": "parcel index.html",
"test": "echo \"Error: no test specified\" && exit 1",
"start": "parcel src/index.html",
"build": "npm run clean && parcel build src/index.html --public-url '.'",
"deploy": "ipfs add -r --quieter dist"
},
"keywords": [],
Expand Down
29 changes: 22 additions & 7 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,32 @@

A website for decoding CIDs

- build: `npm run build`
- dev: `npm run dev`
- add to ipfs: `npm run deploy`
## Getting started

Linux users: If you see `Error: ENOSPC: no space left on device` errors, crank up your max inotify watches:
With node and npm installed, clone the repo and run:

```console
npm i
```
sysctl -w fs.inotify.max_user_watches=524288
echo "fs.inotify.max_user_watches=524288" >>/etc/sysctl.conf

To start the hot-code-reloading dev server:

```console
npm start
```

To build the optimized static website to the `dist` folder:

```console
npm run build
```

To add the `dist` folder to your local ipfs repo and print the root CID:

```console
npm run deploy
```

---
## License

License MIT 2018
1 change: 1 addition & 0 deletions src/img/ipfs-logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions src/img/ipld-tree.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
110 changes: 110 additions & 0 deletions src/img/multiformats-logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 7 additions & 7 deletions index.html → src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
</head>
<body class='sans-serif'>
<header class='pv3 ph2 ph3-l bg-navy cf'>
<a href="https://multiformats.io/" title='ipfs.io'>
<img src="https://ipfs.io/images/ipfs-logo.svg" class='v-mid' style='height:50px' />
<a href="https://ipfs.io/ipns/multiformats.io/" title='ipfs.io'>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, is there a specific reason for linking to not the canonical version? IPNS tends to be a bit slower than just using DNS + IPFS hashes

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did not know that... I'll change them back.

<img src="img/ipfs-logo.svg" class='v-mid' style='height:50px' />
</a>
<h1 class='aqua fw2 montserrat dib ma0 pv2 ph1 v-mid fr f3 lh-copy'>CID inspector</h1>
</header>
Expand Down Expand Up @@ -62,15 +62,15 @@ <h1 class='aqua fw2 montserrat dib ma0 pv2 ph1 v-mid fr f3 lh-copy'>CID inspecto
Base32 CIDv1
</a>
</label>
<div class='f5 sans-serif ma0 fw4 pt2'id="base32cidv1"></div>
<div class='f5 sans-serif ma0 fw5 pt2'id="base32cidv1"></div>
</div>
</section>
<footer class='mt2 pv2 ph2 ph3-l bt b--light-gray'>
<a href="https://multiformats.io/" title='Multiformats' class='dib v-mid'>
<img src="https://multiformats.io/logo.svg" style='height:50px' />
<a href="https://ipfs.io/ipns/multiformats.io/" title='Multiformats' class='dib v-mid'>
<img src="img/multiformats-logo.svg" style='height:50px' />
</a>
<a href="https://ipld.io" title="Interplanetary Linked Data" class='dib v-mid'>
<img src="https://ipld.io/img/ipld-tree.svg" style='height:40px' />
<a href="https://ipfs.io/ipns/ipld.io" title="Interplanetary Linked Data" class='dib v-mid'>
<img src="img/ipld-tree.svg" style='height:40px' />
</a>
</footer>
<script src="./index.js"></script>
Expand Down
File renamed without changes.
File renamed without changes.