Giter VIP home page Giter VIP logo

contract's Introduction

A template to get you started with Cairo 1

Create a repository from this template, clone it locally and run make install. Voilà!

Make commands

  • make install: Sets up the cairo git submodule
  • make build: Builds the cairo 1 compiler
  • make test dir=<path>: Runs the tests in a crate
  • make format: Formats cairo files under src/
  • make check-format: Checks format for files under src/
  • make starknet-compile dir=<path>: Runs starknet-compile on a cairo crate and stores the output under out/
  • make language-server: Builds the Cairo 1 Language Server

Example

make starknet-compile dir=src/erc20
make starknet-compile dir=src/storage

Language server

To get proper syntax highlighting and code navigation in your editor, you will need the Cairo 1 extension. You can find instructions on how to install the vscode extension here. You can build the language server manually by running make language-server, and then edit the configuration file of the extension to point to full path of the executable under target/release/language-server. The language server needs the corelib/ directory to be present in the root directory of the project, hence it is copied from the cairo submodule when running make install.

contract's People

Contributors

th0rgal avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.