Skip to content

Instantly share code, notes, and snippets.

@adamatti
adamatti / BubbleSortTest.py
Last active Nov 1, 2019
Resultado do dojo de python - 04/05/2017 #dojo
View BubbleSortTest.py
import unittest
from sort import BubbleSort
class BubbleSortTest(unittest.TestCase):
def setUp(self):
self.bubble_sort = BubbleSort()
def testSortEmptyList(self):
lista = []
@adamatti
adamatti / .editorconfig
Last active Nov 1, 2019
Default files - Java #bootstrap
View .editorconfig
root = true
[*.{groovy,gradle}]
end_of_line = lf
insert_final_newline = true
charset = utf-8
indent_style = space
indent_size = 4
[Makefile]
@adamatti
adamatti / remove-docker-containers.md
Last active Nov 1, 2019 — forked from ngpestelos/remove-docker-containers.md
How to remove unused Docker containers and images #docker
View remove-docker-containers.md
  1. Delete all containers

     $ docker ps -q -a | xargs docker rm
    

-q prints only the container IDs -a prints all containers

Notice that it uses xargs to issue a remove container command for each container ID

  1. Delete all untagged images
@adamatti
adamatti / README.md
Last active Nov 1, 2019
Docker commands #docker
View README.md
  • stop all containers: docker stop $(docker ps -q)
  • delete all containers: docker rm $(docker ps -aq)
  • delete all images: docker rmi $(docker images -q)
View index.js
const express = require('express');
const app = express();
app.get('/health', function (req, res) {
res.send('Hello World!');
});
app.get('/jokenpo', function (req, res) {
let jogadaJogador1 = req.query.jogador1;
let jogadaJogador2 = req.query.jogador2;
@adamatti
adamatti / README.adoc
Last active Oct 30, 2020
Play with Quarkus #quarkus
View README.adoc
  • Create project:

mvn io.quarkus:quarkus-maven-plugin:1.9.1.Final:create \
    -DprojectGroupId=adamatti \
    -DprojectArtifactId=sample \
    -DclassName="adamatti.HelloResource" \
    -Dpath="/hello"
@adamatti
adamatti / README.adoc
Last active Nov 1, 2019
Sending a message to AWS / local #sample #aws
View README.adoc

Required

How to run:

  • Start AWS local: docker run -p 4576:4576 -p 8080:8080 -e SERVICES=sqs localstack/localstack

  • Optional: create file payload.json with your content

@adamatti
adamatti / 00_README.md
Last active Nov 1, 2019
Meetup Micronaut #meetup #micronaut
View 00_README.md
@adamatti
adamatti / openhackrs-principios.adoc
Last active Dec 13, 2019 — forked from dwildt/openhackrs-principios.txt
Open Hack RS - Funcionamento base e princípios.
View openhackrs-principios.adoc

OpenHackRS - Open Hack Rio Grande do Sul

TL;DR; Queremos fazer eventos para codar. Reunir pessoas interessadas em desenvolvimento de software, interessadas em aprender novas tecnologias.

Quer participar de eventos? Se inscreva no https://www.meetup.com/OpenHackRS/.

Quer ajudar a organizar eventos? Procura pelo dwildt no Telegram.

Qual a ideia?