Bananas Development Blog: share your thoughts

Kopierst Du noch, oder entwickelst Du schon ?

Vagrant. Development environments made easy.
Vagrant uses Oracle’s VirtualBox to build configurable, lightweight, and portable virtual machines dynamically. The first couple of pages serve to introduce you to Vagrant and what it has to offer while the rest of the guide is a technical walkthrough for building a fully functional web development environment. The getting started guide concludes by explaining how to package the newly created vagrant environment so other developers can get up and running in just a couple commands.


(R)?ex
With (R)?ex you can manage all your boxes from a central point through the complete process of configuration management and software deployment.


Diese Software sollte das Entwickeln und die Handhabung von vielen Projekten vereinfachen und man kann sich auf die eigentliche Arbeit konzentrieren.

Joe Armstrong. Analyse der aktuellen Programmiersprachen-Welt

Joe Armstrong hat Erlang erfunden und hat eine lange Zeit der Programmiersprachen-Entwicklung miterlebt.

Hier ist mal eine aktuelle Einschätzung über die vielen Programmiersprachen die es heute so gibt.

Hier zum gleich lesen und als Backup:
Old timer here ...

When I learnt programming (1967) ,
I could choose between FORTRAN and (it was rumoured, Algol)
but nobody knew anything about Algol so it was FORTRAN.

The turn round time for a program was three weeks

week 1 - write code on paper forms - send to computer center to be
turned into punched cards
week 2 - review punched cards, if ok send to machine
week 3 - results

The compiler helpfully stopped at the first syntax error which got you back
to week 1 -
so if you had say ten errors in your program it would take 30 weeks to get
it running.

This is a pretty good environment - teaches you not to make mistakes and to
think first.

By about 1970 I was at university and turn round times were down to 4 hours
and you could punch your own cards - it was still FORTRAN

By 1974 I got access to a computer -- a honywell DDP516 - with a colossal
32 KB memory.
So the 474 pass FORTRAN compiler could compile a hundred line program in
less than a week
(or so ...)

Things improved - I went to CERN and used the CRAY1 this could compile 100K
lines of
FORTRAN in 1 picosecond (ie about a zillion times slower than my mobile
phone today)

Still Fortran.

In 1974 (ish) I got to play with a DEC10 - Now I could write FORTRAN,
Basic, assembler
and it had time-sharing (wow) turn round times of seconds. If I'd been In
the USA I'd be Bill Gates,
but this was Edinburgh.

In 1976 I got a job programming a NORD10 in FORTRAN/Assembler and it was
really fast
turn round times of seconds.

In 1980 ish I was still programming in FORTRAN - I forget the name of the
machine
all files were in one directory, no full-screen editor, no revision control
system,
I wrote about 150K lines of FORTRAN for it.

1985 I joined Ericsson - wow a VAX11/750 - new languages to learn. Bye bye
FORTRAN

I learnt (with various degrees of proficiency) Lisp, Prolog, awk, bash,
smalltalk, TCL,
and became proficient in Prolog (aggghhh - the beauty ....)

I also played with just about any language I could get my hands on (ML,
forth, ...)

Then I (1986) got into my Erlang Phase (I couldn't really learn Erlang,
'cos it didn't exist,
so I invented it) - it was really an outgrowth of Prolog+Smalltalk with a
bit of error recovery
concurrency and distribution throw in.

Then I learnt (badly) C - But Mike Williams said my C was crap and looked
like Fortran so he
binned my C ... (why use malloc and free and pointers anyway ...)

I saw C++ coming and read the book - or at least tried to read the book -
there's a dent
in the wall behind my piano, where the book hit the wall - Improvements to
C should make things
easier not more complicated, I thought.

Time passed.

I tried Java (not impressed, ok it's better than C++, but oh so verbose, I
used to get
programmers "white fingers" when programming FORTRAN you have to write
hundreds of lines
to do the smallest thing - Java seemed similar - so verbose) - I also
(later) tried
Python (ok), Ruby (ok), Lua(better), Javascript(I like :-)

It's actually taken me quite a long time to learn all these languages, and
they didn't
all come at once. I had a good 15 years of FORTRAN - long enough to get
good at it,
10 years of Prolog, 20 years of Erlang etc.

I also had a long time to assimilate the new ideas - the ideas in
programming come pretty slowly
- once every twenty years or so somebody has a really good idea,
programming
today hasn't improved much in the last 20 years - it was mess then and it's
still a mess.

IDE's and revision control systems have just made matters worse - now you
have all the
old versions of the mess as well as the mess itself, and the IDE means you
can't even see the mess.

The best IDE in the world is your BRAIN - it's a zillion times better than
these
clicky things.

What's this got to do with education?

Suppose you're starting off.

You can choose between twenty odd languages (all of them good for one
reason or another)
what took me 40 years to learn, you must try to understand in 2-3 years,
this is just not possible.

What languages should a beginner learn, what languages should a school
teach?

Now we get to the paradox of choice - because there are so many
alternatives it becomes
impossible to choose.

Old timers say "choose the language appropriate to the problem" when you
know 20 odd
languages (with varying degrees of proficiency) this is easy to say - but
If you know
two languages Java and C then this isn't much help.

There are literally problems where the solution in a CLP language is a few
lines
and is thousands of lines in C.

What would I recommend learning?

- C
- Prolog
- Erlang (I'm biased)
- Smalltalk
- Javascript
- Hakell / ML /OCaml
- LISP/Scheme/Clojure

A couple of years should be enough (PER LANGUAGE).

Notice there is no quick fix here - if you want a quick fix go buy "learn
PHP in ten minutes"
and spend the next twenty years googling for "how do I compute the length
of a string"

The crazy think is we still are extremely bad at fitting things together -
still the best
way of fitting things together is the unix pipe

find ... | grep | uniq | sort | ...

and the fundamental reason for this is that components should be separated
by well-defined protocols in a universal intermediate language.

Fitting things together by message passing is the way to go - this is basis
of
OO programming - but done badly in most programming languages.

If ALL applications in the world were interfaced by (say) sockets + lisp S
expressions
and had the semantics of the protocol written down in a formal notation -
then we could
reuse things (more) easily.

Today there is an unhealthy concentration on language and efficiency and
NOT on how things fit together and protocols - teach protocols and not
languages.

And teach ALGORITHMS.

Cheers

/Joe

(The dates in the above are approximate)

© Joe Armstrong 2013

Neues aus dem Maschinenraum

Endlich mal wieder Zeit gefunden um Neoterisch ein wenig polieren und mein CMS weiter zu entwickeln.

Neoterisch:
Bereich Wissenschaft mit besonderen Hochschulen und Forschungseinrichtungen Deutschlands. ( Wenn jemand noch weitere Vorschläge hat, nur her damit. )
Optisch habe ich die Schrift verändert. Hoffe es lässt sich nun ein wenig besser lesen.

WordPulse:
Arbeiten im Usermanagement und Umstellung der Passwortspeicherung in der Datenbank auf bcrypt.


Insipid 1.5

Insipid bietet nun die Möglichkeit Screenshots für einen Bookmark zu erstellen. Bei Anlage und auch nachträglich.

Verwendet wird dazu phantomJS
PhantomJS is a headless WebKit with JavaScript API. It has fast and native support for various web standards: DOM handling, CSS selector, JSON, Canvas, and SVG.


Dazu muss phantomJS seperat installiert werden. Sollte aber keine Problem sein. Es gibt Builds für Windows, GNU/Linux und OSX

Download insipid version 1.5



HLStats 1.63

Well, just said it.

Now it is done.

Download, install and give some feedback.


Gentoo und Mate

Die Installation von Mate unter Gentoo funktioniert einwandfrei.

Die sourcen werden über einen overlay angeboten.

Also einfach den overlay mate über layman installieren,
emerge mate -pv
um zu sehen, dass sehr viele Pakete ein ~x86 brauchen sowie zusätzliche Keywords.

Nun ein emerge mate. Fertig.


Neues Mate release

Für Alle die lieber bei Gnome2 bleiben wollen hat der Gnome Fork Mate eine neue Version veröffentlicht:

- Numerous bug fixes
- All conflicts with GNOME were fixed
- All configuration files were moved to ~/.config/mate
- An undo/redo feature was added in Caja
- Libmate’s mate-open command is now faster to open applications.
- Mate settings daemon now supports the PulseAudio and GStreamer backends
- New applications: mozo (alacarte fork), python-caja, caja-gksu, caja-image-converter
- Mate themes were renamed to avoid conflicts with GNOME
- A new MATE wallpaper was added
- MATE now features its own icon


Ich rate jedem der Gnome3 nicht mag ( will ich diese Oberfläche die Gnome3 mir bietet, dann bleibe ich bei OSX ) diesen Fort zu probieren.


Wettern über PHP

Ach ja, PHP ist schon die Qual der Wahl wenn es um Anwendungen geht, die über das HTT-Protokoll arbeiten.

Leider ist PHP nicht das Beste wenn es um Genauigkeit geht. Es finden sich immer wieder Fehler die eigentlich nicht da sein sollten.

Large HTTP request Content-Length header values result in failed malloc() call
wrong equality of string numbers

Und hier noch ein längerer Artikel über das Design in PHP:
PHP: a fractal of bad design
PHP is an embarrassment, a blight upon my craft. It’s so broken, but so lauded by every empowered amateur who’s yet to learn anything else, as to be maddening. It has paltry few redeeming qualities and I would prefer to forget it exists at all.



How the Linux Kernel is build

Aufschlussreiches Video wie der Workflow des Linux Kernel abläuft. Es zeigt auch wo und wie der Linux Kernel verwendet wird und welchen Einfluss er hat.

Sehr informativ.




Map of CPAN

Wer schon immer mal wissen wollte, wie so die Verteilung der einzelnen Bestandteile von CPAN ist, dem seit hiermit geholfen:

Map of CPAN


Backups sind wichtig

What Is Happening To The jQuery Plugins Site?

Die haben einfach mal die Plugin Site gelöscht. Einfach so. Aber das Beste kommt noch. Das letzte Backup ist EIN Jahr alt ! Was für Vollpfosten sind denn da am Werk ?

In the process of deleting on the spam, all the plugins were deleted and we didn’t have a recent backup


Wenn man wirklich was bereinigen will, dann macht man doch erst recht ein Backup ?
jQuery war ja noch nie mein Fall und dies bestätigt sich mit so einem stümperhaften Anfängerfehler...

Design PSD Freebies

Immer schön zu sehen, wenn es Dinge für umme gibt:

Stunning Pixel Perfect PSD Freebies #1
Stunning Pixel Perfect PSD Freebies #2

Addthis à la Heise

Facebook macht ja leider was es will ( Aber da die Benutzer ohne viel nachzudenken mit laufen.... ). Nun hat das deutsche Recht leider ein Problem mit der Art und Weise wie Facebook mit den Daten umgeht.

Daher hat sich der Heise Verlag für die eigene Webseite was überlegt.

Nun kann man sich die Idee kopieren und bei sich einbauen. Was aber wenn man leider schon andere Social-Share-Dienste verwendet ?

Bei der Verwendung von Addthis habe ich nun eine Lösung gefunden die das Verhalten nachbaut.

Hier ist der HTML Teil der beim ersten Aufruf der Seite geladen wird.
Klicken und aktivieren für mehr Datenschutz Klicken und aktivieren für mehr Datenschutz


Wie man sieht gibt es zwei "Blöcke". Der Erste ist der normale Addthis Teil, der die gängigen Icons anzeigt.
Der zweite Block beinhaltet erster mal nur zwei Icons die man anklicken kann. Diese Aktion wir via Javascript hinzugefügt.

Dazu kommt noch ein wenig jQuery:

$(window).load(function() {
	$("#socialMediaExtended").click(function() {
		var url = "/getSocialBarExtended";
			
		$.ajax({
			url: url,
			cache: false,
			success: function(html) {
				$('#socialFrame').html(html);
				addthisInit();
			}
		});
	});
	
	addthisInit();
});

function addthisInit() {
	var addthisScript = 'http://s7.addthis.com/js/250/addthis_widget.js#domready=1';
	if(window.addthis) {
		window.addthis = null;
	}
	$.getScript(addthisScript, function() { addthis.init(); });
}


Wenn die Seite geladen wurde, wird mit der Funktion "addthisInit" das JavaScript von Addthis geladen. Wichtig dabei ist der Parameter "#domread=1" am Ende der URL. Damit wird der erste Block mit den Addthis Aktionen hinterlegt und kann verwendet werden.

Wenn man nun in dem zweiten Block auf ein Icon klick wird der AJAX Aufruf ausgeführt. Das was dabei zurückkommt wird in das Element mit der ID "socialFrame" rein geschrieben. Wobei der bestehende Inhalt überschrieben wird.



Nach dem der Inhalt geladen worden ist, wir die Funktion "addthisInit" erneut aufgerufen und Addthis neu geladen und somit werden die neuen Buttons eingebunden und funktionieren.

Auf diese Weise werden die IFrames der Anbieter (Facebook, Google etc.) nur auf Wunsch geladen.

Bei Fragen einfach fragen ;-)

Humor am Montag Morgen

Ok, ist nicht so der Brüller, aber ein wenig schmunzeln sollte es doch bewirken:

http://howfuckedismydistro.com/
und
http://howfuckedismydatabase.com/

Mif.tree mit Mootools 1.3.2

Das aktuelle Release von Mif.Tree funktioniert nicht mit Mootools 1.3.2 nocompat. Nun habe ich mal damit angefangen die Beispiele mit der aktuellen Version von Mootools zum fliegen zu bringen.

Hier der Code.

Wer mitmachen will kann sich hier beteiligen.