Git Product home page Git Product logo

haskell-project's Introduction

EMURGO Academy Haskell Course: Solo Project

This repository contains a preconfigured Haskell development environment, allowing you to start coding in Haskell with zero installation using Gitpod and a browser-based version of VS Code.

The environment contains a skeleton for a simple Haskell project, designed as a starter for the solo project of EMURGO Academy's Haskell course.

Create Your Environment

  1. Fork this repository
  2. Copy the link to your new repository and prefix it with "https://gitpod.io/#" in your browser
  3. Click Continue with GitHub and Authorize gitpod-io
  4. Wait for the environment to build. This can take a while the first time.
  5. Select "VS Code Browser" as your editor.

Build Your Project

This template contains a basic structure for a simple Haskell project. Add your project code to the empty *.hs files:

  • src/Lib.hs: this module is intended to contain the core business logic of your program - it should consist of pure functions (not IO actions). You can rename this or create additional modules as needed (be sure to adjust the other-modules section of emurgo-project.cabal to reflect any changes/additions)
  • src/Types.hs: use this module to define any custom types and synonyms that you'll use in other modules
  • src/Actions.hs: this module should contain helper IO actions that will be used inside the main action of app/Main.hs. Most of your effectful code should live in this module.
  • app/Main.hs: compose a minimal main action using helper actions defined in src/Actions.hs to run your application (this is what will be used if you )

Add any additional packages you need for your project below base in the build-depends section of emurgo-project.cabal. Follow instructions if you encounter any errors due to a "hidden package": these refer to packages that are part of the standard library but aren't imported into a Haskell project by default. The editor tooling will identify the name of the package you need to add to build-depends in such cases.

Use cabal repl in the terminal and the :l command followed by a specific module name (Lib, Types, Actions, etc.) to test your code.

Use cabal run to run your completed program.

As you complete the assignments, stage, commit and push your changes to Github using the Source Control tab in the left panel.

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.