Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Rails and Jupyter
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"metadata": {
"collapsed": false
},
"outputs": [
{
"data": {
"text/plain": [
"true"
]
},
"execution_count": 1,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"rails_root = \"/Users/leonard-chin/src/ghe.ckpd.co/adtech/ads\"\n",
"FileUtils.cd rails_root\n",
"require './config/boot'\n",
"APP_PATH = File.expand_path('config/application') unless defined?(APP_PATH)\n",
"require APP_PATH\n",
"Rails.application.require_environment!"
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {
"collapsed": false
},
"outputs": [
{
"data": {
"text/plain": [
"\"development\""
]
},
"execution_count": 2,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"Rails.env"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Ruby 2.2.3",
"language": "ruby",
"name": "ruby"
},
"language_info": {
"file_extension": "rb",
"mimetype": "application/x-ruby",
"name": "ruby",
"version": "2.2.3"
}
},
"nbformat": 4,
"nbformat_minor": 0
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.