This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @nil ~/tmp/ekg2-20081227 $ make | |
| make all-recursive | |
| Making all in plugins | |
| Making all in logs | |
| /bin/sh ../../libtool --tag=CC --mode=compile gcc -DHAVE_CONFIG_H -I. -I../.. -fvisibility=hidden -g -O2 -Wall -std=c99 -MT logs_la-main.lo -MD -MP -MF .deps/logs_la-main.Tpo -c -o logs_la-main.lo `test -f 'main.c' || echo './'`main.c | |
| gcc -DHAVE_CONFIG_H -I. -I../.. -fvisibility=hidden -g -O2 -Wall -std=c99 -MT logs_la-main.lo -MD -MP -MF .deps/logs_la-main.Tpo -c main.c -fno-common -DPIC -o .libs/logs_la-main.o | |
| main.c: In function 'logs_open_file': | |
| main.c:664: warning: implicit declaration of function 'strlcpy' | |
| main.c:666: warning: implicit declaration of function 'strlcat' | |
| main.c: In function 'logs_simple': |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def scan(text) | |
| text =~ /^([0-9]{1,2})[-\.]([0-9]{1,2})[-\.]([0-9]{4})/ | |
| end | |
| loop do | |
| loop do | |
| puts "Podaj pierwsza date (format: dd-mm-rrrr)" | |
| if scan(d1 = gets.chop!) | |
| break |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/local/bin/ruby | |
| class Dupa | |
| def initialize(param) | |
| @param = param | |
| end | |
| def show | |
| puts @param | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/local/bin/ruby | |
| class Dupa | |
| class << self | |
| def puf | |
| [] | |
| end | |
| end | |
| end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class Dupa | |
| class << self | |
| attr_accessor :param | |
| def show | |
| puts @param | |
| end | |
| end | |
| end | |
| a = "napis" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/local/bin/ruby | |
| require 'pp' | |
| text =<<END | |
| Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec malesuada. Cras enim tellus, mattis a, consequat at, ullamcorper id, tortor. Class aptent taciti sociosqu ad litora torquent per conubia nostra, per inceptos himenaeos. Maecenas lorem. Nam posuere diam sit amet tellus. Duis convallis justo eget leo. Suspendisse potenti. In mattis cursus tellus. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Quisque consequat cursus enim. | |
| Sed mattis dui nec magna. Proin eget neque a velit volutpat tempor. Vestibulum blandit tellus et velit. Donec venenatis lectus et velit. Integer quis est eu urna scelerisque cursus. Nullam ac nibh eu sapien imperdiet malesuada. Nullam auctor facilisis eros. In consectetur. Fusce ligula. Quisque aliquam erat id ante. Curabitur pulvinar vulputate libero. Phasellus risus. Aenean dapibus, ipsum eu condimentum consectetur, nulla tortor adipiscing metus, quis blandit nulla ante vitae ligula. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ cpan | |
| cpan[7]> o conf prerequisites_policy follow follow | |
| prerequisites_policy [follow] | |
| Please use 'o conf commit' to make the config permanent! | |
| cpan[8]> o conf commit | |
| commit: wrote '/opt/local/lib/perl5/5.8.8/CPAN/Config.pm' | |
| cpan[9]> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # mam dwie tablice: | |
| # a = [1,2] | |
| # b = [3,4], | |
| # chce je polaczyc w nastepujacy sposob: [[1,3],[2,4]] | |
| # pytam wiec irba jak to zrobic :-) | |
| >> a = [1,2] | |
| => [1, 2] | |
| >> b = [3,4] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/local/bin/ruby | |
| require 'rubygems' | |
| require 'hpricot' | |
| require 'open-uri' | |
| require 'pp' | |
| # sudo gem install hpricot | |
| # http://www.katalogiseo.info/str-2-1,60.html |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class AddIndexes < ActiveRecord::Migration | |
| def self.up | |
| change_table(:songs) do |t| | |
| t.index(:hash_id, :unique => true) | |
| end | |
| change_table(:record_songs) do |t| | |
| t.index([:song_id, :record_id]) | |
| end |