Code Monkey home page Code Monkey logo

pyplayground's Introduction

PyPlayground by Kevo

This is a collection of miscellaneous Python utilities built using online classes and many helpful references from around the web. Many of these utilities and games are straight-up copy/pasted from StackOverflow posts and Python community forums. I plan to clean up and organized this repo over time. I use the IntelliJ PyCharm IDE for development.

Project Dependencies

$ sudo python3 -m ensurepip
$ pip3 --version
$ pip3 install pytest
$ pytest --version
$ pip3 install pylint

# UI Dependencies
$ pip3 install kivy

# AI and Data Science Dependencies
$ pip3 install torch
$ pip3 install matplotlib

# I don't remember what these do, but I installed them :)
$ pip3 install django
$ pip3 install flask

PyCharm Interpreter Setup

To fix "unresolved references" errors in individual python packages, you'll need to right-click directories with module imports, right click, and select "Mark Directory As... Sources Root"

Inspect the .idea/misc.xml file and confirm that the jdk-name is "Python 3.7", and not "Python 3.7 (Project Name)".

Inspect the .idea/Project.iml file and confirm there is an orderEntry element for:

<orderEntry type="jdk" jdkName="Python 3.7" jdkType="Python SDK" />

Contributing

There are only loosely defined contribution guidelines as of right now. Please configure the commit template by executing:

git config commit.template ./COMMIT_TEMPLATE.md

Use the Changelist Summary section to document:

  • Explanations that justify the changes
  • Interesting things you learned
  • Note any bugs or anomalies you encountered on the way

The "Diff Title" (commit subject line) can be derived by completing the phrase, "After this commit, the [ application | library | documentation ] will..." or "When this diff is merged it will...". It is good to keep these under 72 characters, and high level.

The summary can often be as easy as answering the question: "What code changes were made and what is the expected behavior once landed?".

When opening a Pull Request, please fill out the Motivation, Test Plan and Related PRs / Issues whenever applicable.

Git Workflow References

Useful git commands for quickly traversing repos:

# Display your git configuration
git config --list
git config --global -l

# Display all remote branches
git branch --remote

# Concise view of git history
git log --oneline

# Visual graph of git history
git log --oneline --graph --all --decorate --abbrev-commit

# See how many lines of code you've changed
git diff --shortstat

# Pushing from a local repository to GitHub hosted remote
git remote add origin [email protected]:USERNAME/REPO-NAME.git

# Clone your fork to your local machine
git clone [email protected]:USERNAME/FORKED-PROJECT.git

# Creating a new remote branch
git checkout master
git pull
git checkout -b pr-new-feature
git push -u origin pr-new-feature

# Delete a remote branch
git push origin :pr-merged-feature

# Remove a git ignored file that is being tracked
git rm -r --cached .
git add .

# Stash your local changes
git add .
git stash save "Implement a new whizbang feature"
git stash apply stash@{1}

# Preview your stashed changes
git stash list
git stash show -p stash@{1}

# Un-commit and stage changes from most recent commit
git reset --soft HEAD~1

GitHub Standard Fork & Pull Request Workflow

# Show which Git branches are tracking remote and upstream (source repo forked from)
git branch -vv

# Keeping a fork up-to-date
git remote add upstream git://github.com/ORIGINAL-USERNAME/FORKED-PROJECT.git
git fetch upstream
git pull upstream master

# List all remote pull requests
git ls-remote origin 'pull/*/head'

# Fetch a specific pull request into a local branch and with a custom name
git fetch origin pull/50/head:pr-new-feature

# Fetch a pull request from a fork repo and patch it as a local branch
git fetch [email protected]:username/ForkedPaymentApp.git refs/pull/50/head:pr-forked-feature

pyplayground's People

Contributors

helloimkevo avatar

Watchers

 avatar

pyplayground's Issues

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.