New Civilization News    
 Ruby on Rails5 comments
picture 14 Dec 2005 @ 15:15, by ming. Internet
Ruby on Rails 1.0 was released yesterday.

Grrr, I have too little time.

I had heard about Ruby and Ruby on Rails for quite some time, but didn't get around to looking more closely before recently.

Ruby is an elegant object-oriented language created in Japan some years ago by Yukihiro Matsumoto. I had looked at it several times, but however good it sounded, there really has to be an exceptional reason for changing the language one programs in. The biggest value is usually in knowing one's tools really well, as opposed to just changing everything whenever another language or platform comes along with slightly better features.

As far as the web is concerned, I first made programs in Perl, because that was basically the obvious choice in 1995. I did shopping cart programs, chat programs, and various other things. But Perl is just too damned cryptic, and I never felt overly comfortable with it.

Then PHP started happening, and it just seemed so much more practical to be able to embed code directly into webpages, and it was more clean and straightforward. So, I switched without much hesitation. Since then I've done hundreds of thousands of lines of PHP code, and PHP has grown into the most widespread solution for coding for webpages.

I've looked at other things in-between. Like Python. More of a "real" language, in that it makes it easier to make clean and well-structured programs that are easy to maintain. But that in itself wasn't enough to switch. But then I looked at Zope, which is a fabulous content management system and development framework, which makes a lot of hard things easier, and which is supported by loads of available modules. I was excited by that, and wanted to switch all my work to Zope. But after a couple of projects, I just felt kind of stupid. If I just used the pre-packaged modules, it was a piece of cake, but in developing new stuff, I just ended up not really grasping the "Zope Way". The people developing the core stuff are obviously super-smart, but so much so that I couldn't easily follow what they were talking about. So I ended up not going any further with that.

Now, Ruby on Rails is a framework built on top of Ruby. It could have been done in other languages, but Ruby lends itself very well to the purpose. It is developed, initially single-handedly, by David Heinemeier Hansson, a young Danish developer. Who is obviously also super-smart, but who additionally has a knack for making things extremely simple, and for just doing everything right. It supports the best practices for development, it supports most things that currently are cool and happening, like Ajax, it is well structured, easy to test, easy to deploy, etc. And with Ruby on Rails you don't pride yourself on how many lines of code you've written and how long it has taken, but quite the opposite. You'll brag about having written some major application in a few weeks, with just a few thousand lines of code.

Rails is built on a fixed, but flexible structure, or pattern, rather, called MVC. Model, View, Controller. The models keep track of the data, connect with databases, validate the data, and store the business rules for the data. The controllers receive requests from the users for doing different kinds of actions. The views are templates for what is presented to the user. That's nothing really new, but it is a good way of organizing an application. One could do that in PHP, but typically one doesn't. Now, Rails enforces a certain structure. There's a set of directories where these various things are stored, and there are certain naming conventions for what they're called. That some of these things are set and known in advance is in part what makes it very simple. A Rails principle is "Convention over Configuration". If we know that the model is always found in the models directory, and that it is named to correspond to the database table, and a few other conventions, we suddenly have little need for configuration files that define where things are and what goes with what.

Another basic principle is "Don't Repeat Yourself" (DRY). Meaning, one should really only do something once. If you have a rule that says that you can not order more than 10 of a given item, there should be one and only one place to say that. Most programmers would want to follow a rule like that, but in most systems it is hard to stay true to it in practice. Not so with Rails, as there typically already is one right place to store that item, so there's no doubt about it.

The online video demos for Rails are mind-blowing. You know, like write a simple weblog program in 15 minutes. If you just want to try Ruby itself, here's a great little interactive tutorial.

Well, I haven't gotten much further than installing Ruby and Rails on my machine and going through a few tutorials. But I'm very impressed, and I think this probably will be a way I'll go.

I'm an expert at PHP programming, and I've done a number of fairly impressive things. But it tends to end up being a bit of a mess. You can do a quick thing in PHP really, really quickly. But a complex program in PHP is very complex. And after you've done it, you discover that there isn't any very good way of testing it, and things break whenever you change something. And everybody does things a little differently, so if you get the job of changing something in somebody else's program, it usually looks like a big pile of spaghetti, however cleverly it might have been written.

I just spoke with one of the people from a company I worked with for several years, developing big things in PHP. I had wondered why I hadn't heard from them for a few months. Turned out that in the meantime they had converted their whole operation to Rails, and they are extremely happy with it, and everything was much easier. That's some folks with very high-volume websites and a few dozen servers. And no wonder they don't need me any more.

Luckily Ruby and Rains are so relatively simple that one can become an expert faster than in various other arenas. Oh, it is not a complete no-brainer, either. Rails can seem a bit intimidating at first. No graphical interface or anything. You're editing text files and running command-line utilities. The productivity mainly starts when one is fluent with all the basic pieces, and one intuitively knows where things go.

Anyway, the best places to learn are the two main bibles, which are lying right here next to me. Programming Ruby and Agile Web Development with Rails. You can read them online too, for that matter.

Ruby and Rails are often connected with "agile" or "pragmatic" programming. These are keywords for modern methods of fast and flexible development which are very different from the traditional slow and linear methods. You know, traditionally one would learn to develop software according to a certain Structured Development Life Cycle (SDLC) approach, which involves copious amounts of formal proposals, specifications, etc. You know, first a committee of people would do feasibility studies, then it would go to an analyst who would make models and specs, etc. And the programmers would be told what to do, essentially. And when they discover that it isn't a great idea to do it that way, or when, later, one discovers that it wasn't really what was needed, it is a bit cumbersome to change. The Agile, Pragmatic or Extreme approach would rather be to go very light on the specs and analysis, and get down to work ASAP, but to do it very quickly, with very short incremental phases, like daily updates, and to do it, as much as possible WITH the stakeholders who need the result. Like, preferably sit down with the end users, and change stuff and show them right away. One could theoretically do that with any language, like PHP, although it isn't easy, and one would probably be crazy to hope to do that with Java or C++. But if you're working with a framework that all the way through is geared towards working like that, it comes much more naturally.

Anyway, I could sure use a 10X productivity boost. And right now Rails looks like the most likely candidate in the programming arena. Plus, I want to be cool too.  More >

 All Disasters, nothing interesting about recovery7 comments
13 Dec 2005 @ 20:54, by oasiian. Broadcasting, Media
Notice how almost always, the News is about all the bad stuff happening? Earthquake here, Murder there, car crash somewhere...and then a little bit of politics, which at least in Canada are always depressing.  More >

 The Death Penalty
picture 13 Dec 2005 @ 02:59, by jmarc. Legal, Justice
I don't like it. I'm against it. People who are for it will often ask, well, what if you or your family were the victim of a killer? Wouldn't you be for it then? Probably. But, so far, so good for us, we haven't been hurt in that way thank God, If something like that happened to my people, I would be thinking from a very emotional state. The government should, SHOULD be operating from a rational state though. Shouldn't be in the revenge business. Should be above that. Because if that is a final solution for a government then it follows that it may be right for an individual. Or that's how the thinking could go, followed to it's logical conclusion.  More >

 Old Civilization: Summing Up1 comment
11 Dec 2005 @ 06:44, by shreepal. Philosophy


Mind is the sole light. Reason is the only test of right or wrong. Truth is the supreme object of search but it can only be revealed by reason. Mind searches around for truth of the existence and gives its judgement. With the development of science, we go on knowing more. Science is based on mind and reason. In its highest flight, mind gives light about itself. Mind tells that as we depend on body senses to get data of world around us and the human mind processes this data, what we get is the result of the mind's processing, and this result may have some part of the subjective adulteration of mind. There is an unbridgeable gap between the world as it actually exists in itself and the world, as we know of it as the result of our processing. There is no way to bridge this gap through mental means.


Reason & desires

Mind and science, which is dependent on it, observe and analyse the world around us. As a result we get that exists is matter and by analysis we get the laws of nature. These two things are the fundamental truths. Whatever contradicts these two things is false. It is legitimate and morally justified knowing the world in this manner by mind and act on its conclusions. By using mind, we know that exists is material. Material world is vast and to know its extent, nature, property it is necessary to explore the material world. To know the truth, we should explore outer space, interior of atom, look inside the genes, and penetrate the earth and oceans. Whatever knowledge we get out of this exploration, we should use in the cause of human beings comforts.

Our body is made up of not only the mind but also the sense organs. Body requires its demands to be met. It is morally justified to meet the demands of body. We know by analyzing by our mind that it is better alternative to co-exist by meeting demands of maximum numbers of people to the maximum extant than to meet all demand of a single person to the maximum and risk mutual conflict and destruction. So demands should be met within reasonable limit so as to avoid the conflict. If the conflict may be managed or averted, it is justified to meet the demands of a person or a group of persons to the maximum. To meet the bodily demands of human beings, it is necessary to produce the means of satisfaction of these demands. It is morally justified to produce the means of comfort to the maximum. For economic development it is necessary, as economic science tells us, to create more demands of people even by artificial methods like advertisements and then to meet such inflated demands by offering them items of comforts (manufactured goods). This creates an interdependent chain of cause and effect of consumption, lower cost of production by producing more, use of technologies so as to reduce dependence of human work-force, elimination of weaker manufacturer by resorting to competition so as to reduce cost of production and price etc. To create the climate of free demand, free supply, free production of the things needed, democracy is the most suitable political system. It is morally justified to consume more. It is morally justified to make people aware of their needs that were non-existent or lay dormant by advertisement and to maximise their consumption.


Consuming man: An Ideal Society

It is reasonable and moral to spread this model around the world so that maximum human being may get the benefit of this comfort-oriented model of way of life. It is reasonable that this model should be extended from local areas to national levels, from national to international level. All means should be used to ensure that this model defeats the alternative models, if found it contradicting in any part of the world. Therefore, it is reasonable and morally justified for the leaders of society to gear it towards consumerism.

In this pursuit, it is morally justified to resort technology to reduce dependence on human labour. Advertisement may be resorted to create needs of people that lay dormant. There is no wrong in elimination of weak by strong to make goods of comfort cheap. Since this is an ideal model of society, there is no wrong in the use of force against those who do not subscribe or conform to these ideals to make sure that this social model survives at the international level.

There is no moral wrong in pursuing a national and global system wherein entire world's natural resources may be used in sustainable manner to meet the inflated and unsatiatable desires of human beings. It is economic development of man. If in the process monopoly of natural resources in the hands of a few persons is created, and war among nations is fought in defence of this social order, there is nothing wrong in it so long as the troublesome things are planned and managed by mind.  More >

 Zimbabwe6 comments
11 Dec 2005 @ 01:50, by nemue. Activism
Over 700,000 people homeless with no means of support due to the action of their government!!!! And still the world stands by and does nothing. Commonwealth countries still trade with this despotic government, as do many other developed countries.

The UN offered temporary tents for the homeless but the government rejected them.
In case you are not aware why these people are homeless it is because the government bulldozed their shanty houses. They bulldozed them but didn’t bother to provide the displaced with any means to survive. And still the voice of the world is silent. How long can we continue to turn a blind eye?

[link]  More >

 Making Something Out of Nothing7 comments
10 Dec 2005 @ 16:19, by vector8. Spirituality
Last Wednesday, a new reality television show started on Channel 4 called Space Cadets. It's about twelve ordinary members of the public who have been recruited to train as space cadets. A few of them will spend time orbiting space. The cadets are flown to Russia to have their space training.

What the cadets don't realise is they are in a "disused military base" in Suffolk in the UK. The television company has gone to great lengths to make the training ground look and feel like Russia. These cadets seriously believe they are now in Russia and being trained to go to space.  More >

 A Day...13 comments
9 Dec 2005 @ 23:29, by swanny. Violence, War
Friday Dec 9, 2005

A Prayer for the day...

As your child oh Universe
I offer this unto you

Just a space of prayer and silence for all
the hostages and the hostage takers.
May we over come our differences and
learn and grow to live in peace and harmony.

Amen  More >

 December 9th (inspired by Anemone)
picture9 Dec 2005 @ 10:48, by judih. Ideas, Creativity
____________________

a flaming sandstorm
screams maelstroms in my mind
fire–eyed phoenix wails
re-birthing through infinity's scales

a wild-eyed artist
overturns paint cans from mountaintops
a sunset with no conception of time

begone the beige of blandness
forge pigments where no colour's found
turn it on, blast it wider, sing the sky alive  More >

 5. REVELATION, the Wrong Reality, AUTOMATIC CONTROLS.6 comments
8 Dec 2005 @ 19:57, by bapty. Social System Design
Our institutions, especially those of law and order, finance and politics, do not exist for the prime purpose of benefitting humanity according to moral truth. They are there both to permit and control instinctive behaviour according to Machine reality.  More >

 A little less than 7 years till the big day0 comments
8 Dec 2005 @ 07:48, by oasiian. Ideas, Creativity
I'm beginning to just have a disgust with society as it stands, and it's sad, because while we should appreciate what wonders we have, we should also note...its worldly cost.  More >



<< Newer entries  Page: 1 ... 109 110 111 112 113 ... 279   Older entries >>


These are news items gathered or contributed by NCN members


Previous entries
2015-10-02
  • Release of the iviCivi Project

  • 2015-10-01
  • Anarchy vs. Psychopaths in Control

  • 2015-09-23
  • Om Ah Hum Mantra

  • 2010-09-25
  • CHINA’S 3-GORGES DAM: DAMNING ECO-FASCIST CATASTR0PHE DISCOURSE

  • 2010-09-23
  • WORLD KNOWLEDGE - WELTWISSEN (1710 - 1810 - 1910 - 2010)
  • fbi hacks my NEWCIV Site.

  • 2010-09-22
  • Who Wins?

  • 2010-09-21
  • Our StressOut Program for Suicide Prevention with Mindfulness

  • 2010-09-20
  • Quote for today...

  • 2010-09-16
  • From "Max Sandor's Tales to his grandson"

  • 2010-09-12
  • Alignment or Realignment?

  • 2010-07-31
  • Innovation Yantra
  • Randy Paush - Lessons for Life

  • 2010-07-30
  • from Baudrillard to Verger: Diversification Vs Global Norms

  • 2010-07-22
  • Cartographers of No Man's Land
  • PUNISH BUSH & NEO-CONS FOR WAR CRIMES!

  • 2010-07-20
  • Getting other people to do stuff

  • 2010-07-16
  • Considerations on writing

  • 2010-07-14
  • Therapy Dogs Serve our Wounded Warriors
  • Consciousness of Pattern

  • More ..

    Categories
  • Activism (97)
  • Altered States (32)
  • Alternative Money Systems (17)
  • Broadcasting, Media (20)
  • Business (19)
  • Children, Parenting (28)
  • Communication (63)
  • Communities (71)
  • Conspiracy (34)
  • Counseling, Psychology (23)
  • Crime, Policing (7)
  • Death & Dying (14)
  • Developing World (19)
  • Economics, Financing, Banking (51)
  • Education (34)
  • Energy Sources (19)
  • Engineering (1)
  • Entrepreneurs, Money Making (19)
  • Environment, Ecology (123)
  • Exercise, Fitness (1)
  • Extraterrestrials (27)
  • Farming (14)
  • Futurism (13)
  • Globalization (29)
  • Government, Public Sector (46)
  • History, Ancient World (38)
  • Housing, Building, Architecture (10)
  • Ideas, Creativity (318)
  • Internet (49)
  • Inventions (6)
  • Investigation, Intelligence (23)
  • Knowledge Management (21)
  • Legal, Justice (24)
  • Liberty, Sovereignty (14)
  • Medicine, Healthcare (46)
  • Music (30)
  • Natural Health & Healing (27)
  • Neighborhood (12)
  • Networking (19)
  • Nutrition, Cooking (7)
  • Old Age, Retirement (4)
  • Organizational Development (12)
  • Paranormal (12)
  • Peace (35)
  • Performing Arts (9)
  • Personal Development (80)
  • Philosophy (94)
  • Politics (120)
  • Poverty (4)
  • Preparedness, Self-Reliance (12)
  • Privacy, Security (1)
  • Publishing (3)
  • Recreation, Fun (59)
  • Relationships (19)
  • Religion (40)
  • Science (48)
  • Sexuality (16)
  • Shared Purpose (30)
  • Social System Design (47)
  • Space Exploration (23)
  • Spirituality (391)
  • Systems Thinking (31)
  • Technology (37)
  • Transportation (9)
  • Travel (22)
  • Violence, War (103)
  • Visual Arts, Graphics (63)


  • Recent Comments:
    2017-05-04
  • cara mengeringkan luka operasi caesar: helty

  • 2017-05-02
  • Ritu Singh: Service

  • 2017-04-29
  • Suhana Khan: High Profile Escorts in Delhi
  • help with programming: help with programming

  • 2017-04-28
  • Help With Assignments: Help With Assignments Online
  • Escorts Service Gurgaon: Escorts in Gurgaon
  • windows movie maker: windows movie maker
  • Call Girls in Delhi: Delhi Call Girls

  • 2017-04-27
  • Galaxy Note 8 Release Date: Galaxy Note 8
  • escorts Bangalore: escorts Bangalore
  • bottle flip: 11

  • 2017-04-26
  • Finance Dissertation Help Provider: Education
  • Agen Judi Bola: hello
  • BandarQ Online: great
  • Bandar Poker: thanks

  • More ..


    MonTueWedThuFriSatSun
    1 2 3
    4 5 6 7 8 9 10
    11 12 13 14 15 16 17
    18 19 20 21 22 23 24
    25 26 27 28 29 30

    Search for:

    [Advanced Search]
    [All Articles]

    Members can post news items and comments in the member area.

    Information and opinions are the responsibility of the posters and do not represent any official position of NCN. Please do your own verification and make up your own mind.


    This is RSS channel information for syndication purposes

    Syndication