Git Product home page Git Product logo

movie-box's Introduction

movie-box

Update a gist to contain your recently watched movies from trakt.tv


๐Ÿ“Œโœจ For more pinned-gist projects like this one, check out: https://github.com/matchai/awesome-pinned-gists

โœจ Inspiration

This code was heavily inspired by @jacc's music-box.

๐ŸŽ’ Prep Work

  1. Create a new public GitHub Gist (https://gist.github.com/).
  2. Create a token with the gist scope and copy it. (https://github.com/settings/tokens/new).
  3. Create a Trakt.tv Application (https://trakt.tv/oauth/applications/new).
  4. Copy the API token.

๐Ÿ–ฅ Project Setup

  1. Fork this repo.
  2. Go to your fork's Settings > Secrets > Add a new secret for each environment secret (below).
  3. Activate github workflows on Actions > I understand my workflows, go ahead and run them.
  4. Star your own fork to trigger the initial build. Then the gist will update hourly. You can then go to your profile and pin the gist.

๐Ÿคซ Environment Secrets

  • GIST_ID: The ID portion from your gist url https://gist.github.com/<github username>/<gist ID>.
  • GH_TOKEN: The GitHub token generated above.
  • TRAKT_ID: The Client ID you got from creating a Trakt.tv app.
  • TRAKT_USERNAME: Your Last.fm username.
  • MOVIE_BOX_MODE: Select the box mode from three options: movies, shows and stats.

๐Ÿ•ต๐Ÿพ Hacking suggestions

  • You can set up CI on Travis if you want to modify this Github Action. You just have to configure the environment secrets as environment variables on Travis. A build will be triggered on every push for the develop branch. Careful, your gist WILL be updated.

  • You can also test the script locally with Lando and Docker:

    • Install Docker Community Edition according with your operating system

    • Install Lando according with your operating system.

    • Install a git client.

    • Clone your fork of the repository.

    • Open a terminal and navigate to the newly created folder.

    • Change to the develop branch.

        git branch develop
      
    • Create a .env file with the content of the environment secrets as variables, like this (with real values):

        GIST_ID=xxxx
        GH_TOKEN=xxxx
        TRAKT_ID=xxxx
        TRAKT_USERNAME=xxxx
        MOVIE_BOX_MODE=xxxx
      
    • Execute the following command to create the docker image (first time only):

        make image
      
    • Execute the following command to start the project:

        make start
      
    • Execute the following command to stop the project (you can also hit ctrl+C):

        make stop
      

movie-box's People

Contributors

dependabot-preview[bot] avatar luisalejandro avatar zijinoier 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.