-
Yapılandırmalar eski yerinde
/etc/unicorn
Örnek:
RAILS_ROOT=/opt/medical
RAILS_ENV=development -
Ayrıca Rails app config,
app_path = "/opt/medical"
# graphics.py | |
"""Simple object oriented graphics library | |
The library is designed to make it very easy for novice programmers to | |
experiment with computer graphics in an object oriented fashion. It is | |
written by John Zelle for use with the book "Python Programming: An | |
Introduction to Computer Science" (Franklin, Beedle & Associates). | |
LICENSE: This is open-source software released under the terms of the | |
GPL (http://www.gnu.org/licenses/gpl.html). |
#!/usr/bin/python | |
# -*-coding:utf-8-*- | |
print "hello emin ve digerleri" |
from warnings import warn | |
def buildParseTree(fpexp): | |
L,R,O,V = 1,2,3,4 | |
state = None | |
fplist = fpexp.split() | |
pStack = Stack() | |
eTree = BinaryTree('') | |
pStack.push(eTree) | |
currentTree = eTree | |
for i in fplist: |
def printexp(tree): | |
sVal = "" | |
if tree: | |
if tree.left == None and tree.right == None: return str(tree.getRootVal()) | |
sVal = '(' + printexp(tree.getLeftChild()) | |
sVal = sVal + str(tree.getRootVal()) | |
sVal = sVal + printexp(tree.getRightChild())+')' | |
return sVal |
# A DNS change to Rubygems.org is causing lingering issues. Namely, | |
# rubygems.org and production.s3.rubygems.org are still pointing to | |
# the old address. See: | |
# http://twitter.com/#!/gemcutter/status/30666857698557952 | |
# The symptoms: | |
# $ gem install benelux --version 0.5.17 | |
# ERROR: Could not find a valid gem 'benelux' (= 0.5.17) in any repository | |
# ERROR: While executing gem ... (Gem::RemoteFetcher::FetchError) |
RSpec.configure do |config| | |
config.before(:suite) do | |
ActiveRecord::Base.establish_connection database['one'] | |
DatabaseCleaner.strategy = :deletion | |
ActiveRecord::Base.establish_connection config.database['two'] | |
DatabaseCleaner.strategy = :deletion | |
end | |
config.before(:each) do |
Factory.define :item do |f| | |
include ActionDispatch::TestProcess | |
f.name "Macbook Pro 15" | |
f.price_in_dollars 1500 | |
f.photo fixture_file_upload('/files/avatar.jpg', 'image/jpg') | |
end |
#!/usr/bin/env python | |
# Plot a graph of Data which is comming in on the fly | |
# uses pylab | |
# Author: Norbert Feurle | |
# Date: 12.1.2012 | |
# License: if you get any profit from this then please share it with me | |
import pylab | |
from pylab import * | |
xAchse=pylab.arange(0,100,1) |
Yapılandırmalar eski yerinde /etc/unicorn
Örnek:
RAILS_ROOT=/opt/medical
RAILS_ENV=development
Ayrıca Rails app config,
app_path = "/opt/medical"
# coding: utf-8 | |
require 'savon' | |
require 'awesome_print' | |
class KPSSorgu | |
# T.C. Kimlik ile Kişi Sorgulama - Konfigürasyon | |
@@tc_bilgi_client = Savon.client( | |
wsdl: "http://192.168.33.25/KPSService/servicetckimliksorgula.asmx?WSDL", | |
namespace: "http://tempuriTCKimlik.org/", |