This file contains 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
ivan:~/src/chkrootkit-0.49 → make sense | |
gcc -DHAVE_LASTLOG_H -o chklastlog chklastlog.c | |
chklastlog.c:85: warning: ‘utmp’ is deprecated (declared at /usr/include/utmp.h:96) | |
chklastlog.c: In function ‘main’: | |
chklastlog.c:97: warning: ‘lastlog’ is deprecated (declared at /usr/include/utmp.h:90) | |
chklastlog.c:98: warning: ‘utmp’ is deprecated (declared at /usr/include/utmp.h:96) | |
chklastlog.c:154: warning: ‘utmp’ is deprecated (declared at /usr/include/utmp.h:96) | |
chklastlog.c:155: warning: ‘utmp’ is deprecated (declared at /usr/include/utmp.h:96) | |
chklastlog.c:166: warning: format ‘%ld’ expects type ‘long int’, but argument 3 has type ‘int’ | |
chklastlog.c:166: warning: format ‘%ld’ expects type ‘long int’, but argument 4 has type ‘uid_t’ |
This file contains 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
desc "Dump the current production database to a MySQL file" | |
task :dump_remote, :filename do |t, args| | |
if args | |
@filename = args[:filename] | |
else | |
@filename = "db-backups/production_data-#{Time.now.strftime("%Y-%m-%d-%H%M")}.sql" | |
end | |
puts @filename | |
end |
This file contains 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
# Copyright 2011 Ivan Storck | |
# Rakefile to manage automated local / remote sync of PHP projects like WordPress and Joomla | |
# Assumptions: | |
# Git is the version control system | |
# Only tested with ssh shortcuts in .ssh/config and public keys but should work with username and password too | |
# for WordPress , .gitignore ignores wp-config.php | |
# for Joomla, .gitignore ignores configuration.php | |
require 'rake' | |
require 'net/ssh' |
This file contains 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
ivan:~/Development/ruby/clients/cadvbe/cadvbesearch [git:master?] → set -x ; cd ~/Development/ruby/clients/cadvbe/cadvbesearch ;type rvm | head -1 | |
+ set -x | |
+ cd /Users/ivan/Development/ruby/clients/cadvbe/cadvbesearch | |
+ builtin cd /Users/ivan/Development/ruby/clients/cadvbe/cadvbesearch | |
+ local result=0 | |
+ __rvm_project_rvmrc | |
+ local cwd | |
+ cwd=/Users/ivan/Development/ruby/clients/cadvbe/cadvbesearch | |
+ : | |
+ [[ -z /Users/ivan/Development/ruby/clients/cadvbe/cadvbesearch ]] |
This file contains 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
# ruby-1.9.2-p180 | |
require 'twitter' #gem install twitter | |
require 'ap' #gem install awesome_print | |
Twitter.configure do |config| | |
config.consumer_key = 'top secret' | |
config.consumer_secret = 'top secret' | |
config.oauth_token = 'top secret' | |
config.oauth_token_secret = 'top secret' | |
end |
This file contains 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
ivan:~/Development/ruby/testcms [git:master?] → rails generate refinerycms_blog | |
create db/migrate/20110520213837_create_blog_structure.rb | |
create db/migrate/20110520213838_add_user_id_to_blog_posts.rb | |
create db/seeds/refinerycms_blog.rb | |
------------------------ | |
Now run: | |
rake db:migrate | |
------------------------ | |
ivan:~/Development/ruby/testcms [git:master?] → rake db:migrate | |
(in /Users/ivan/Development/ruby/testcms) |
This file contains 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
ivan:~/Development/ruby/refinerycms/ivanenviroman [git:master] → bundle exec rake wordpress:import[~/Downloads/wordpress.2010-07-01.2011-05-01.xml] --trace | |
** Invoke wordpress:import (first_time) | |
** Execute wordpress:import | |
** Invoke environment (first_time) | |
** Execute environment | |
rake aborted! | |
Given file '/Users/ivan/Development/ruby/refinerycms/ivanenviroman/~/Downloads/wordpress.2010-07-01.2011-05-01.xml' no file or not readable. | |
/Users/ivan/.rvm/gems/ruby-1.9.2-p180@refinerycms/bundler/gems/refinerycms-blog-3fcf7e43873d/lib/tasks/wordpress.rake:21:in `block (2 levels) in <top (required)>' | |
/Users/ivan/.rvm/gems/ruby-1.9.2-p180@refinerycms/gems/rake-0.9.0/lib/rake/task.rb:205:in `call' | |
/Users/ivan/.rvm/gems/ruby-1.9.2-p180@refinerycms/gems/rake-0.9.0/lib/rake/task.rb:205:in `block in execute' |
This file contains 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
heroku rake db:migrate | |
(in /app) | |
rake aborted! | |
uninitialized constant Rake::DSL | |
/app/.bundle/gems/ruby/1.9.1/gems/rake-0.9.2/lib/rake/tasklib.rb:8:in `<class:TaskLib>' | |
/app/.bundle/gems/ruby/1.9.1/gems/rake-0.9.2/lib/rake/tasklib.rb:6:in `<module:Rake>' | |
/app/.bundle/gems/ruby/1.9.1/gems/rake-0.9.2/lib/rake/tasklib.rb:3:in `<top (required)>' | |
/app/.bundle/gems/ruby/1.9.1/gems/rake-0.9.2/lib/rake/rdoctask.rb:20:in `<top (required)>' | |
/app/.bundle/gems/ruby/1.9.1/gems/railties-3.0.8/lib/rails/tasks/documentation.rake:1:in `<top (required)>' | |
/app/.bundle/gems/ruby/1.9.1/gems/railties-3.0.8/lib/rails/tasks.rb:15:in `block in <top (required)>' |
This file contains 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
ivan:~/Development/ruby/IvanEnviromanRefinery [git:master+] → bundle exec rspec ../refinerycms-link/ | |
.............................F. | |
Failures: | |
1) BlogPost bookmark links must have a link url if it is a link | |
Failure/Error: Factory.build(:post, | |
expected valid? to return false, got true | |
# /Users/ivan/Development/ruby/refinerycms-link/spec/models/blog_post_spec.rb:197:in `block (3 levels) in <top (required)>' |
This file contains 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
require 'acts-as-taggable-on' | |
require 'seo_meta' | |
class BlogPost < ActiveRecord::Base | |
is_seo_meta if self.table_exists? | |
default_scope :order => 'published_at DESC' | |
#.first & .last will be reversed -- consider a with_exclusive_scope on these? |