Giter Site home page Giter Site logo

gosock's Introduction

GoSOCK

This is a basic implementation of a chatroom using websockets. Embedded in this project is also a custom logging library

Build Status Docker Pulls

Overview GoDoc

Install

    go get github.com/deven96/gosock

Usage

To use the logging library, call this snippet preferably in the init

    import (
        "github.com/deven96/gosock/pkg/custlog"
    )
    
    func init() {
        // name the log file "test.log" and write to it in append mode
        def_writers := custlog.DefaultWriters("test.log", true)
        custlog.LogInit(def_writers)
    }

    func main(){
        custlog.Info.Println("This is just information")
        custlog.Warning.Println("This is just a warning")
        custlog.Error.Println("This is just an error")
    }

To run the project,

    cd $GOPATH/github.com/deven96/gosock

    # run the project in develop mode
    go run *.go

    # generate executable for current os
    go build github.com/deven96/gosock

    # run the executable
    ./gosock

For using the binaries only, read Binaries usage

Example Interaction

Example interaction

TODO

  • Incorporate a standard Golang ORM
  • Include User and Message models
  • Extend chat interface to include login and signup
  • Include face avatar on every message
  • Create a Rudeness API that can detect how unsensitive a statement is
  • Kick avatar out after every 3 overly rude messages
  • Deploy on Linode server
  • Linode deploy should be linked to Travis pipeline

License (MIT)

This project is opened under the MIT 2.0 License which allows very broad use for both academic and commercial purposes.

gosock's People

Contributors

deven96 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.