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: Add project setup information and docs site #4

Merged
merged 6 commits into from
Dec 29, 2022
Merged

Conversation

ospencer
Copy link
Member

@ospencer ospencer commented Dec 28, 2022

Closes #1

@ospencer ospencer temporarily deployed to github-pages December 28, 2022 19:51 — with GitHub Pages Inactive
docs/index.md Outdated
There are a number of flags we'll need to pass to the compiler.

- `-I near-sdk-gr` to tell the compiler where the SDK is;
- `--wasi-polyfill near-sdk-gr/src/near/wasi.gr` to stub out WASI functionality;
Copy link
Member

Choose a reason for hiding this comment

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

I don't like that this is in src/

Can we bring these down a directory?

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't follow what you mean here!

@ospencer ospencer temporarily deployed to github-pages December 28, 2022 22:41 — with GitHub Pages Inactive
@ospencer ospencer temporarily deployed to github-pages December 28, 2022 22:46 — with GitHub Pages Inactive
Copy link
Member

@phated phated left a comment

Choose a reason for hiding this comment

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

Few more things

docs/index.md Outdated
There are a number of flags we'll need to pass to the compiler.

- `-I near-sdk-gr` to tell the compiler where the SDK is;
- `--wasi-polyfill near-sdk-gr/near/wasi.gr` to stub out WASI functionality;
Copy link
Member

Choose a reason for hiding this comment

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

Talked with Oscar on discord. I think we should move the polyfill outside of the near/ directory (and into the root) so this can become near-sdk-gr/wasi.gr

docs/index.md Outdated

## Configuring VSCode

If you use VSCode to develop your contract, you can tell the language server where the NEAR SDK is by setting the `grain.cliFlags` setting to include `-I near-sdk-gr`.
Copy link
Member

Choose a reason for hiding this comment

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

I believe you need all the flags passed to the LSP so that recompiles don't happen, right?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, though we don't currently advertise people do that (like for compiling for release)

Copy link
Member Author

Choose a reason for hiding this comment

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

I'll add a note about putting the whole thing though

const path = require('path');
const cp = require('child_process');
const which = require('which');
const path = require("path");
Copy link
Member

Choose a reason for hiding this comment

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

Can we drop the grainfind file now that the LSP does everything it used to do?

Copy link
Member Author

Choose a reason for hiding this comment

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

Sure but I think that's out of scope of this PR

const path = require('path');
const cp = require('child_process');
const which = require('which');
const path = require("path");
Copy link
Member

Choose a reason for hiding this comment

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

See above about grainfind

@ospencer ospencer temporarily deployed to github-pages December 29, 2022 00:14 — with GitHub Pages Inactive
@ospencer ospencer temporarily deployed to github-pages December 29, 2022 00:18 — with GitHub Pages Inactive
Copy link
Member

@phated phated left a comment

Choose a reason for hiding this comment

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

Looks good 🎉

@ospencer ospencer merged commit c6c42ff into main Dec 29, 2022
@ospencer ospencer deleted the oscar/docs branch December 29, 2022 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

How to compile
2 participants