20111223

How to Google


http://enkurs.lv/ka-pareizi-lietot-google-mekletaju/

20111130

Crop To Selection in GIMP

-Open File.
-Place selection (e.g. overlay image to be pixelperfect -> Select the overlay layer and do an "Alpha to selection")
-Image->CropToSelection
-Edit->CopyVisible&Create->fromClipboard or just save it as needed.

20110825

mysql user with priviledges to his db

mysql> create database user_name DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_general_ci;
mysql> grant usage on *.* to user_name@localhost identified by 'user_pwd';
mysql> grant all privileges on user_name.* to user_name@localhost;

20110821

20110817

minecraft server

as daemon:
/etc/init.d/minecraft start
/etc/init.d/minecraft stop
/etc/init.d/minecraft restart
/etc/init.d/minecraft status

connect to terminal screen:
screen -r minecraft

disconnect from screen with:
Ctrl+A D

20110810

Android cheap phone

HTC Wildfire S
LMT (Cena Ls 19 + 6.00 * 24 mēn.) = 163Ls

LG Optimus One P500
LMT: (Cena Ls 9 + 4.00 * 24 mēn.) = 105Ls

Samsung Galaxy Ace
LMT: (Cena Ls 19 + 6.50 * 24 mēn.) = 175Ls

HTC Desire
LMT: (Cena Ls 29 + 8.50 * 24 mēn.) = 233Ls

LMT ar Formula 8:
Wildfire S: 163 + 192 = 355
P500: 105 + 192 = 297

Bite ar 3,5Ls pieslēgumu:
Wildfire S: 227 + 84 = 311
P500: 169 + 84 = 254

20110805

svn diff coloured (vim) + citi sīkumi

grep -rin 'text' ./ --include=*.php
find -name '*.php' -exec egrep -Hn 'SEARCHTERM' {} \;
find . -exec grep -H -n 'hello' {} \;
delete ALOT of logfiles:
find . -type f -name "*.log" -delete

treeview in console:
find . -type d -print | sed -e 's;[^/]*/;|__;g;s;____|; |;g'

svn diff file.ext | view -


http://www.zalas.eu/viewing-svn-diff-result-in-vim

P.S. SVN DIFF with previous version:
svn diff -r PREV file

svn diff -r HEAD:PREV file


SVN PROPGET
svn proplist .
svn propget -R svn:ignore .
svn propedit svn:ignore .


SVN CACHE IGNORE (previously commited)
$ cd /path/to/cache/folder
$ svn stat
###bunch of M's...
$ svn rm * --keep-local
$ svn ci -m 'clearing cache'
$ svn propset svn:ignore '*' .
$ svn up
$ svn ci -m 'cache ignored'


P.S.S. Delete files like 'tmp_*' last accessed at least 2 days ago:
find . -name 'tmp_*' -atime +2 -exec rm {} \;

Number of files in directory:
ls | wc -l

Directory size:
du -hs

Check syntax errors in php script:
php -l ./script.php

TAB settings in Vim:
:set tabstop=4
:set shiftwidth=4
:set expandtab
:retab

Delete ALOT of files:
find /home/dir/ -name "*.tmp" | xargs /bin/rm


How to maintenance page:
http://www.techiecorner.com/97/redirect-to-maintenance-page-during-upgrade-using-htaccess/
mysqldump .. parameters.. | gzip > db_backupfile_tablename.sql.gz

quick dump - NB! could be inconsistent state:
mysqldump -h hostname -u username -ppassword --lock-tables=false --quick dbname | gzip > dbname.sql.gz
gunzip < dbname.sql.gz | mysql -h hostname -u username -ppassword dbname

select av.ModulID, GROUP_CONCAT(distinct av.ID order by av.ID SEPARATOR '&') as concatted from Lang l left join AttributeValue av on l.ID = av.LangID where TextKey like 'si_%' and l.ModulID = 21 group by av.ModulID;

select table_schema, (SUM(data_length) + SUM(index_length))/1048576 as size_in_MB from information_schema.tables where table_schema = 'db_name' group by table_schema;

select table_schema, table_name, (SUM(data_length) + SUM(index_length))/1048576 as size_in_MB from information_schema.tables where table_schema = 'db_name' group by table_schema, table_name;

create database dbname;
grant usage on *.* to dbuser@localhost identified by 'dbpass';
grant all privileges on dbname.* to dbuser@localhost;

Linux:
/etc/init.d/mysqld start
/etc/init.d/mysqld stop
/etc/init.d/mysqld restart
OSX:
sudo /usr/local/mysql/support-files/mysql.server start
sudo /usr/local/mysql/support-files/mysql.server stop
sudo /usr/local/mysql/support-files/mysql.server restart

sql injection: http://websec.ca/kb/sql_injection

http://vim.wikia.com/wiki/Search_and_replace
:highlight Comment ctermfg=green/blue/yellow

php style: http://pear.php.net/manual/en/standards.php

global search/replace with grep and sed:

grep -rl --include="*.php" "oldstring" . | xargs sed -i 's/oldstring/newstring/g'

20110729

20110718

Postfix install on Ubuntu

Postfix install tutorial
Relaying postfix smtp via gmail

Test email sending with:
echo “test email” | mail -s “Hello” ***@gmail.com

DNS configuration for mail and web (GoDaddy)

Switch to advanced mode so that you can edit more than one line at a time.
Change the @ A(Host) @ record to your new IP.
Delete every CNAME except for www and ftp
Add the mail A(Host) Record for mail pointing to the same new ip.
Delete the MX record with Priority 0.
Change the priority 10 record to mail.YOU-DOMAIN-NAME.COM
Add new SPF record and follow the following prompts
Choose “an ISP or other mail provider”
inbound tab: all inbound servers may send mail
outbound tab: all addresses in A records
PTR tab: include PTR
The resultant line should look like “v=spf1 a mx ptr ~all”

http://scottelkin.com/programming/how-to-properly-configure-godaddy-dns-settings/

20110715

rFactor Historic GT & TC mod car list

GTC-65
AC Cobra
Austin Healey 3000
Chevrolet Corvette 65 Coupe
Chevrolet Corvette 65 Roadster
Ford GT40
Jaguar E-Type Coupe
Jaguar E-Type Lightweight
Lotus Elan 26R
Lotus Elite
Mercedes 300SL
Porsche 911S
Renault Alpine A110
Shelby Daytona Coupe
Shelby GT 350
TVR Griffith 400

TC-65
Alfa Romeo GTA
Austin Mini Cooper S
Fiat Abarth 1000TC
Ford Falcon Sprint
Ford Mustang
Jaguar MKII
Lotus Cortina

GTC-76
BMW CSL
Chevrolet Corvette
DeTomaso Pantera
Ford Capri 2600RS
Ford Capri 3100RS
Ford Escort RS
Porsche 906
Porsche 911 RS 2.8
Porsche 911 RSR 2.8
Porsche 911 RSR 3.0
Porsche 911 RST 2.8
Porsche 911 ST 2.4
Porsche 911 S 2.0
Porsche 914

Mini Cooper Cup
Austin Mini Cooper S 1,3

Porsche Cup
Porsche 906

Carrera Cup
Porsche 911 RS Cup

Coppa Mille
Fiat Abarth Coppa Mille

LeMans 1972
BMW 2800 CS LM72
Chevrolet Corvette LM72
DeTomaso Pantera LM72
Ferrari GTB/4 LM72
Ford Capri 2600RS LM72
Ferrari GTB/4 LeMans 24H 1972
Porsche 911 LM72

Daytona
Ferrari Daytona GTB/4 LM73
Ferrari Daytona GTB/4 LM75

Mod link

Citi modi:
DRM Revival Mod (v1.1)
Spirit of 76
World Sports Car Championship 1970
CPCC 1300 2010

20110714

Linux Encoding

x264 is currently the best video codec available for Linux, but using it with AVI is not a good idea because this combination is incompatible with most hardware-based playback devices. When DivX (the company) dropped their old codec in favor of H.264, they dropped AVI as well and replaced it with MKV (Matroska). Any "DivX Plus"-certified Blu-ray player or set-top box will be able to play back H.264 in MKV (with AAC audio) but not in AVI.

Rule of thumb:
If you need DivX (version 5/6) compatibility, use Xvid and MP3 in AVI.
If you need DivX Plus (version 7) compatibility, use x264 and AAC in MKV.
If you need Apple iPod/iPhone compatibility, use x264 and AAC in MP4.
If you need HTML5 compatibility, use Theora and Vorbis in Ogg.

20110709

Fuel surge tank

DIY - Fuel surge tank
http://www.sdsefi.com/techsurge.htm

http://cgi.ebay.co.uk/ALLOY-FUEL-SURGE-TANK-SWIRL-POT-RALLY-RACE-/320722167458?pt=UK_CarsParts_Vehicles_CarParts_SM&hash=item4aac87e6a2

20110630

Alfa Romeo Giulia Sprint GTA


santoservice.com

20110628

20110617

75 abs un pedālis

Blade fuse
Also if the brake pedal is "hard" it could be a popped blade fuse. I guess it controls the boost and mine did that and the fuse fixed it.
fraz@alfabb\

Fusible link
PS: The fusible link is located in a black, rectangular plastic "box" about two inches long, a half inch wide by a half inch tall mounted atop the driver's fender well, near the ignition coil. The top flips open to access the fuse link.

http://www.alfabb.com/bb/forums/milano-75-1987-1989/36178-brake-pedal-hardened-stiff-brake-failure-2.html

20110606

75

- Aizmugurējie gultņi (1 | 2 | 3)
- Savienojumi gaisa trubām (47mm)
- Degvielas trubiņas ? (hansaflex?)
- nomainīt priekš/pak. stabilizatorus?


- salīmēt wind deflector
- pieregulēt ķēdes spriegotāju
- trosīte kapotam(?)
- bumper lip?
- salona radiatora regulators
- eļļas tausta upgrade

+ vadītāja el.loga nočekošana
+ pasažiera el.loga pogas remonts
+ dzinēja ventilatora releja maiņa
+ Svečvadi (eparts)
+ Spriegotājs ķīļsiksnai (+no šrota)?
+ Blīvslēgs kloķenēm (Hansaflex)
+ Radiators (eparts)
+ Kolektora blīves (eparts) un flancis (metinātājs)...
+ Savilcēji/žņaugi
+ noregulēt roceni
+ lambda (1 | 2)?

+ jostu stiprinājumi
+ izņemt beņķus & sametināt domkrata vietu
+ sametināt kolektora flanci
+ nomainīt trosīti bagāžnieka atvēršanai
+ jostas

Seals:




Camshaft back plate seal:
- 60567272 - SEAL GASKET
- 60513263 - SEAL GASKET (out of production)

Phase variator seal:
- 60512937 - SEAL (SUBSTITUTED BY 60534186 ?)

Lower distributor seal:
- 60544957 - SEAL

Seal shops: Hansaflex | Wurth

Signalizacija:
http://www.75.qubos.com/gpage2.html
http://www.the12volt.com/carsecurity/page5.asp
tikai remote locking?

20110602

linux notes

/usr/bin/mpd
sudo alsamixer
unmute (m) Master un PCM

If mp3 high frequencies cause crackling sounds (low quality), change /etc/mpd.conf
audio_output {
type "alsa"
name "my ALSA device"
samplerate_converter 0
}


Useful system monitor for console Linux: saidar

20110420

Jāiepērk / 75 suspension


Sunītis
Domkrats
Grunts/Krāsa/Šķīdinātājs
Skrūves?
Dzesēšanas šķidrums?
Bremžu šķidrums?

Priekšējās piekares How-to un optimālais regulējums:]
- How-to adjust height | Separating balljoints
- AlfaBB RJ
- Camber adjustment and shims
- Front end settings (-1.3 Camber, 5.3 castor, stock toe)
- Torsion bar removal / metal crack lower A arm
- Lower bushing removal | 2

In general the A arm on the bottom should be set up so that it is nearly level with road surface or optimal at 1/4 inch lower on the ball joint/upright end. This maximizes the lower "A" Arm`s contribution to negative camber on initial turn-in.


The upper joint is easy to separate. Back off the nut and hit the arm near the ball with an air hammer (or regular hammer.) The torsion bar is trying to pull out the ball joint. You just have to help it. I got this tip from Richard Jemison.

20110415

Suda detaļas & interesanti Sud' u projekti

http://www.benavelis.gr/de/catalog.php?ModelId=187

Projekti:
Pilnībā nogruntēts un pārkrāsots: http://forum.alfaclub.eu/viewtopic.php?t=22971
Pārkrāsots: http://forum.alfaclub.eu/viewtopic.php?t=40875
Titan gray sud: http://forum.alfaclub.eu/viewtopic.php?t=20955
Sudraba suds: http://forum.alfaclub.eu/viewtopic.php?t=11804
Pārkrāsots sarkans 5p: http://forum.alfaclub.eu/viewtopic.php?t=27861
Sarkans (rust removal): http://forum.alfaclub.eu/viewtopic.php?t=45617
Giardinetta rust removal (daudz): http://forum.alfaclub.eu/viewtopic.php?t=51151
Giardinetta (Alfachirurg, daudz rust): http://forum.alfaclub.eu/viewtopic.php?t=49256
Bert Kanters 16v in Sud: http://forum.alfaclub.eu/viewtopic.php?t=12790

20110413

Java

I hate you!

p.s. rm /target/classes//

20110328

Rust, priming and color

Labs apkopojums par gruntīm: http://www.mig-welding.co.uk/primer.htm
http://www.autos.com/auto-repair/self-etching-primer-vs-epoxy-primers

Seksī pikčā!



Lielāka bilde te: http://tinyurl.com/5wubb6t

http://andthesearethedays.tumblr.com/

Biturbo

http://www.blenheimgang.com/biturbo-story-part-1/
http://www.blenheimgang.com/biturbo-story-%E2%80%93-part-2/
http://www.blenheimgang.com/biturbo-story-3/
http://www.blenheimgang.com/biturbo-story-4/

20110322

Welding

Dažādi paņēmieni paneļu restaurācijai: retrorides
Atrūsošana ar etiķi: retrorides

Metal forming: metalmeet , retrorides
Metalforming VW bus

Spot welding transaxle Alfas for strength

Bertones restaurācija (achtung - eatable)

20110321

Transaxle alfa springs


http://www.cartuningpoint.de/shop/

Springs
Lower arm bushes (how to)
Rear anti roll bar bushes / front?
Thermostat
Front brake pad guide kit!

20110314

145 list

+Sataisīt salona ventilatoru: guide
+Nomainīt priekšējā paneļa apakšējo daļu (pie iepr.)
-Sataisīt lukturu regulāciju: guide
-Sataisīt ABS (priekšējais kreisais itkā)
-Nomainīt stūres pirkstus (+ savirze)
-Piestiprināt sliekšņus
-Sataisīt signalizācijas pulti (baterijas?/durvju mehānisms?)
-Airbag?
-MAF?
-Diski (15" vasarai vai 16")