How to become successful
This is a quite inspiring speech. Reaching a target or becoming successful takes time and pain. Rewards are difficult to obtain, but when you get it... it is awesome:
Labels: selfgrowth
Ruby, PHP, MySql, Software engineering and more.
This is a quite inspiring speech. Reaching a target or becoming successful takes time and pain. Rewards are difficult to obtain, but when you get it... it is awesome:
Labels: selfgrowth
echo -e "linuxpassword\nlinuxpassword" | passwd linuxuser |
You can use the following script to change the user password as root without having to re-type the password:
#!/usr/bin/expect | |
spawn passwd [lindex $argv 0] | |
set password [lindex $argv 1] | |
expect "password:" | |
send "$password\r" | |
expect "password:" | |
send "$password\r" | |
expect eof |
Just put your code between begin and rescue statements and print the error. An example:
begin
MyApp.run!
rescue Exception => msg
puts "Something went wrong ("+msg+")"
end
Labels: ruby