Skip to content

Instantly share code, notes, and snippets.

View otaviofcs's full-sized avatar

Otávio Sampaio otaviofcs

View GitHub Profile
@otaviofcs
otaviofcs / RStudio notebook example
Last active March 24, 2018 20:10
Exemplo de uso de um RStudio salvando um notebook que pode virar uma página de apresentação (no caso, em html, mas poderia ser PDF,...)
---
title: "opa opa"
output: html_notebook
---
Bibliotecas usadas para esse notebook:
```{r}
#libraries in use....
#install.packages('tidyverse')
#install.packages('stringdist')
# IMPORTANT: This file is generated by cucumber-rails - edit at your own peril.
# It is recommended to regenerate this file in the future when you upgrade to a
# newer version of cucumber-rails. Consider adding your own code to a new file
# instead of editing this one. Cucumber will automatically load all features/**/*.rb
# files.
require File.expand_path(File.join(File.dirname(__FILE__), "..", "support", "paths"))
# Commonly used webrat steps
# config/environments/test.rb
# WebRat para testes de integração
config.gem 'webrat', :lib => false, :version => '>= 0.5.3'
# spec/support/webrat.rb
require 'webrat'
Spec::Runner.configure do |config|
#!/bin/bash
# Converte uma lista de imagens em 1 pdf único
# Criado Otávio Sampaio (osampaio at riopro dot com dot br)
# para a Riopro, Gestão Inteligente
# http://riopro.com.br
# Depende do imagemagick e do pdftk instalados
# testado no Ubuntu 9.10
# Script to convert images (like jpeg and png) to a single pdf
#
# Creates a matcher to make rspec routes tests in a simple way.
#
# Extracted from:
# http://www.adelphus.com/2009%2F3%2F18%2Frspec-routes-really
# By Ron Hopper
#
# Sample:
#
# Adding map.resources :widgets to your routes