• Stars
    star
    306
  • Rank 136,456 (Top 3 %)
  • Language
    HTML
  • Created over 9 years ago
  • Updated 7 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Code snippets for various programming languages and libraries

The Cookbook Method

A cookbook in the programming context is collection of tiny programs that each demonstrate a particular programming concept. The Cookbook Method is the process of learning a programming language by building up a repository of small programs that implement specific programming concepts. Starting with a Hello World program and building the knowledge piece by piece on top of that.

If you are a beginner, you will probably want to start out with one language like Python and start building up your repetoire of snippets for reference and confidence. If you are a seasoned developer, you may want to start building a cookbook from scratch for a new language you have never used, or keep a cookbook for more advanced topics in a language you are already familiar with.

Here is an example of when my Cookbook comes in handy. Recently I was faced with a situation where I needed to make an HTTP request to an API, parse the JSON response, generate a CSV spreadsheet, and email the spreadsheet. Because I already had my own cookbook snippets for doing each of those three actions, it was really easy to put together a program that did what I needed it to.

Watch the video

The Cookbook Method

Benefits of Building Your Own Cookbook

  • You can share it with others
  • Learn topics that are interesting to you
  • You build up your knowledge in small increments
  • You can see your progress over time
  • You have a library of reference material in your own style.
  • It is quicker than looking up documentation or looking for a Stack Overflow answer.
  • Explore new topics
  • Learn new programming languages.
  • Tips for Building a Cookbook
  • Store your cookbook in a version control system like Git.
  • Keep a to do list of topics or programming languages you want to explore and learn
  • It does not have to be just code. I have a lot of plain text .txt files with notes on things like how to create a Python pip package, creating Ruby Gems, or how to create a runnable JAR in Java. Sometimes tips on installing prerequisites if something was difficult or just notes on how to compile and run programs.
  • It can also be template programs. For example I have a base chrome browser extension that doesn't really do anything itself, but it is a fully functional extension with all the boilerplate done and ready for me to start developing.
  • Programs should be fully runnable and not just chunks of code without context that do not compile and execute
  • Keep the snippets small, simple and to one topic

Example Cookbook Topics

Everyone has different goals with programming so identify topics relevant to your interests. Here are some ideas if you do not know where to get started.

  • Hello, world
  • Getting user input from stdin
  • Taking command line arguments
  • Reading and writing files
  • Using TCP sockets
  • Making HTTP requests
  • Parsing JSON
  • Creating a CSV file
  • Making database connections
  • Playing an audio file
  • Multithreading
  • Drawing 2D graphics to screen
  • Drawing 3D graphics to screen
  • GUI programming

The DevDungeon Cookbook

Contact

John "NanoDano" Leon [email protected] https://www.devdungeon.com

More Repositories

1

reStructuredText-Documentation-Reference

Tutorial and reference for reStructuredText documentation.
45
star
2

OAuth2-Login-Python-Flask-Example

Example Flask app showing how to use "Login with Discord" feature
Python
27
star
3

issh

Improved SSH: Curses TUI to select SSH connection from ~/.ssh/config file
Python
25
star
4

WebGenome

A breadth first web crawler that stores HTTP headers in a MongoDB database with a web front end all written in Go.
Go
25
star
5

Python-Kivy-Flask-Android-Example

A Python Kivy app that runs a Flask web app on desktop/Android
Python
21
star
6

Django-AllAuth-Example

Example of allauth package doing local and social OAuth2 login
HTML
11
star
7

NanoPot

Simple TCP honeypot
Python
8
star
8

BinauralGenerator

Generate custom binaural audio with a GUI.
Java
8
star
9

GPS-Bookmarker-API

Django REST Framework backend for React Native mobile GPS bookmarker app
Python
8
star
10

NanoLifePy

Pygame implementation of Conway's game of life (nanolife package on pypi)
Python
7
star
11

Cathy

Artificial intelligence (AI) chat bot for Discord written in Python 3
Python
6
star
12

DiscordRpgBot

Simple framework for a Discord RPG bot
Python
6
star
13

Django-Contrib-Auth-Example

Simple registration, login, logout, password reset, and password change project as a reference or template for larger projects
HTML
6
star
14

AndroidPortScanner

Simple port scanner for Android written in Kotlin
Kotlin
5
star
15

PayPalFlaskIPN

Example of PayPal IPN processing with a Flask app
HTML
5
star
16

Bug-Bounty-Browser-Extension

Tool for assisting in bug bounty hunting process
JavaScript
4
star
17

Rust-WebAssembly-Game-of-Life

Simple Game of Life implemented using Rust and WebAssembly. Done following https://rustwasm.github.io/docs/book/game-of-life/introduction.html
Rust
4
star
18

CVE-2019-6340-Drupal-8.6.9-REST-Auth-Bypass

CVE-2019-6340 Drupal 8.6.9 REST Auth Bypass examples
Python
3
star
19

KivyExamples

Kivy for Python examples
Python
3
star
20

Wardriver

Wardrive and generate a Google Earth file with color coded wireless access points and client information
Shell
3
star
21

PortScanCollection

Port scan examples in a variety of languages
C
3
star
22

KivyBitcoinPriceChecker

Kivy app for checking bitcoin price. Works on mobile and desktop
Python
3
star
23

PyQt5-Bitcoin-Price-Checker

Very simple PyQt5 Bitcoin price checker
Python
3
star
24

DiscordMusicBot

Simple bot to play YouTube URLs in a Discord voice channel
Python
2
star
25

DjangoSiteCheckerExample

An example of how to run management commands for Django with a cron job. Example is an app that checks websites and records HTTP status.
Python
2
star
26

HTML-Template

Simple HTML template with Bootstrap, jQuery, Google Fonts, and Font-Awesome icons.
HTML
2
star
27

TcpNull

TCP server for debugging and testing. Discard incoming data or echo it back to client raw or as an HTTP response.
Java
2
star
28

Web-Browser-Extension-Template

Browser extension template ready for development with jQuery and Bootstrap
JavaScript
2
star
29

LanguageLearner

Practice learning a foreign language with this vocabulary and typing tool
Python
1
star
30

Minecraft-Plugin-Template

Template project for Minecraft Bukkit API plugin
Java
1
star
31

awesome-music

Curated list of free music production and sound design tools and tutorials
1
star
32

Minecraft-Plugin-Discord-Notifier

Notifies a Discord channel on Minecraft events
Java
1
star
33

GPS-Bookmarker-React-Native

Simple react native prototype for GPS bookmarking
JavaScript
1
star
34

Cordova-GPS-Tool

Simple mobile app that fetches GPS coordinates to demonstrate Cordova capability
Java
1
star
35

Python-Flask-Template

Application template for Python Flask web applications
HTML
1
star
36

DevNix

Linux distribution customized and themed by John "NanoDano" Leon (Fedora Remix)
Python
1
star
37

Bitcoin-Price-Checker-React-Native

Very basic React Native app to check bitcoin price
JavaScript
1
star
38

Python-App-Template

My app for CLI and PyQt5 based GUI applications
Python
1
star
39

AndroidBitcoinPriceCheckerJava

Simple Java Bitcoin price checker
Java
1
star
40

mysql2excel

Dumps a MySQL table to Microsoft Excel .xlsx spreadsheet.
Java
1
star