A "Best of the Best Practices" (BOBP) guide to developing in Python.
- "Build tools for others that you want to be built for you." - Kenneth Reitz
- "Simplicity is alway better than functionality." - Pieter Hintjens
| <web-app> | |
| <filter> | |
| <filter-name>sitemesh</filter-name> | |
| <filter-class>com.blah.MyCustomSiteMeshFilter</filter-class> | |
| </filter> | |
| <filter-mapping> | |
| <filter-name>sitemesh</filter-name> | |
| <url-pattern>/*</url-pattern> | |
| </filter-mapping> | |
| </web-app> |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
| #!/bin/sh | |
| # From http://www.webupd8.org/2014/03/how-to-install-oracle-java-8-in-debian.html | |
| # | |
| # You need to run this script as root | |
| # | |
| # su - | |
| echo "INSTALLING JAVA 8 AS USER `whoami` " | |
| echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu trusty main" | tee /etc/apt/sources.list.d/webupd8team-java.list |
| package com.company.project.controllers; | |
| import com.company.project.model.api.ErrorJson; | |
| import org.springframework.beans.factory.annotation.Autowired; | |
| import org.springframework.beans.factory.annotation.Value; | |
| import org.springframework.boot.autoconfigure.web.ErrorAttributes; | |
| import org.springframework.boot.autoconfigure.web.ErrorController; | |
| import org.springframework.web.bind.annotation.RequestMapping; | |
| import org.springframework.web.bind.annotation.RestController; | |
| import org.springframework.web.context.request.RequestAttributes; |
When contributing to this repository, please first discuss the change you wish to make via issue, email, or any other method with the owners of this repository before making a change.
Please note we have a code of conduct, please follow it in all your interactions with the project.
| # ... more above ... | |
| # wsfl bash is not a login shell | |
| if [ -d "$HOME/bin" ] ; then | |
| PATH="$HOME/bin:$PATH" | |
| fi | |
| # ssh-agent configuration | |
| if [ -z "$(pgrep ssh-agent)" ]; then | |
| rm -rf /tmp/ssh-* |
| /* | |
| * Handling Errors using async/await | |
| * Has to be used inside an async function | |
| */ | |
| try { | |
| const response = await axios.get('https://your.site/api/v1/bla/ble/bli'); | |
| // Success 🎉 | |
| console.log(response); | |
| } catch (error) { | |
| // Error 😨 |
Copyright © 2017 Fantasyland Institute of Learning. All rights reserved.
A function is a mapping from one set, called a domain, to another set, called the codomain. A function associates every element in the domain with exactly one element in the codomain. In Scala, both domain and codomain are types.
val square : Int => Int = x => x * x| #!/bin/bash | |
| # Enter /opt folder (common folder for user installed programs) | |
| # This script assumes you have proper permissions on /opt | |
| cd /opt | |
| # Download GitKraken | |
| wget https://release.gitkraken.com/linux/gitkraken-amd64.tar.gz | |
| # Extract the Kraken into /opt directory |