GithubHelp home page GithubHelp logo

github_gist_clone's Introduction

Github Gist Clone

This is a clone of Github Gist that runs on rails, and utilizes the ACE javascript library for syntax highlighting.

Getting Started

  1. Install Docker :

     On mac go to: 'https://docs.docker.com/docker-for-mac/install/'
    
  2. Clone the below repo:

     git clone https://github.com/ac7552/github_gist_clone.git
    
  3. In the cloned directory create your own .env with a password like so:

     MYAPP_DATABASE_PASSWORD="example"
    
  4. At the command prompt, while in the newly cloned directory, setup the docker containers with the following command:

     $ docker-compose build
     $ docker-compose up
    
  5. Next, if need be, migrate the rails db with the following commands

     $ docker-compose run website rake db:migrate
    

Debugging/and other tools

  1. For debugging run: docker-compose run --service-ports website
  2. For checking routes: docker-compose run website rake routes
  3. For running migrations: docker-compose run website rails g migration etc

Prerequisites

Docker

##Code Snippet:

  • In the gist.js file there is a language-map you can add to, so that you can deliminate additional languages.
Just add the extension of the language you wish to add.
const languageMap = {
  js: 'javascript',
  py: 'python',
  rb: 'ruby',
  html: 'html',
  css: 'css'
}

Github Gist Clone in Action

Github Gist

Built With

  • Ace - The javascript library used
  • Rails - The Web Framework used
  • Docker - Containers for an easy setup

Authors

  • Aaron Campbell

github_gist_clone's People

Contributors

ac7552 avatar

Watchers

 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.