Latest Radiant Node Release
1.3.0 Energy
Radiant Blockchain Wiki
Official Website
  • Radiant Blockchain
  • FAQs
  • Induction Proof System FAQs
  • Links
  • White Papers
    • Radiant: A Peer-to-Peer Digital Asset System
      • Radiant: un Système d'Actifs Numériques Pair-à-Pair
      • Radiant: 一种点对点数字资产系统
      • Radiant: un sistema de activos digitales electrónico peer-to-peer
      • रेडियंट: एक सहकर्मी से सहकर्मी डिजिटल संपत्ति प्रणाली
      • Radiant: Sistem Kasugihan Aset Digital Peer-to-Peer
      • Radiant: Sistem Aset Digital Peer-to-Peer
    • Radiant Blockchain System Design
  • Programming
    • Radiant Opcodes
    • Pay to Ref
    • Non-Fungible Tokens on Radiant
    • Token-Controlled Contracts on Radiant (Pay to Token)
    • Glyphs Protocol
    • RadiantScript
      • About RXD
      • Command Line Interface
      • Getting Started
      • Guides
        • Writing Covenants & Introspection
        • Syntax Highlighting
      • Language
        • Artifacts
        • Contract Structure
        • Examples
        • Global Functions & Operators
        • Global Variables
        • Language Grammar
        • Types
      • SDK
        • Examples
        • Contract Instantiation
        • Sending Transactions
      • Releases
        • Migration Notes
        • Release Notes
    • scryptlib
      • preimage
        • preimage - Chinese
      • rawstate
      • HashedMap
        • HashedMap - Chinese
      • Chained APIs
        • Chained APIs - Chinese
    • Scrypt Boilerplate
  • Guides
    • Docker
    • Electron Wallet
      • Restore
      • Create multisign
    • Radiant Node
    • Flux
Powered by GitBook
On this page
  • Visual Studio Code (Recommended)
  • Sublime Text
  • Atom
  • GitHub & GitLab
  • Others

Was this helpful?

Edit on GitHub
Export as PDF
  1. Programming
  2. RadiantScript
  3. Guides

Syntax Highlighting

PreviousWriting Covenants & IntrospectionNextLanguage

Last updated 6 days ago

Was this helpful?

When developing smart contracts for CashScript it is useful to have the proper syntax highlighting in your code editor / IDE. If you use Visual Studio Code, there is a dedicated CashScript extension. For other editors it is recommended to install a Solidity highlighting plugin and associate it with .cash files in your editor, since the syntaxes of the two languages are very similar.

Visual Studio Code (Recommended)

For Visual Studio Code a dedicated was developed by community contributor . This plugin works with .cash files and supports syntax highlighting, autocompletion, snippets, linting and even integrated compilation.

Because of the first-class CashScript support, Visual Studio Code together with this CashScript extension is the recommended way to develop CashScript contracts.

Sublime Text

The most popular Solidity plugin for Sublime Text 2/3 is . Install this plugin with , open a .cash file and set Solidity as the syntax language in the Sublime menu bar:

View -> Syntax -> Open all with current extension as ... -> Solidity

This associates .cash files with Solidity, and enables syntax highlighting for your CashScript files.

Atom

The most popular Solidity plugin for Atom is . Install this plugin and add the following snippet to your Config file:

```yaml title="~/.atom/config.cson" core: customFileTypes: "source.solidity": ["cash"]


This associates `.cash` files with Solidity, and enables syntax highlighting for your CashScript files.

## Vim
The most popular Solidity plugin for Vim is [vim-solidity](https://github.com/TovarishFin/vim-solidity). Install this plugin and add the following snippet to your `.vimrc`:

```bash title=".vimrc"
au BufRead,BufNewFile *.cash setfiletype solidity

This associates .cash files with Solidity, and enables syntax highlighting for your CashScript files.

GitHub & GitLab

GitHub and GitLab have syntax highlighting for Solidity built in. To associate .cash files with Solidity highlighting, add a .gitattributes file to your repository with the following contents:

python title=".gitattributes" *.cash linguist-language=Solidity # GitHub *.cash gitlab-language=solidity # GitLab

Others

If your editor is not mentioned above, the steps are likely very similar. Try to find a Solidity syntax highlighting plugin for your editor of choice and find a method to associate .cash files with this Solidity highlighting.

CashScript extension
Nathaniel Cherian
Ethereum
Package Control
language-solidity