Nicholas Rowan, a 22-year-old from Mayfair, is doing time for violating probation. He doesn't want to tell the world about his original crime, and inside the greenhouse on Philadelphia Prison System grounds in the Northeast, it doesn't really matter.

He's coaxing tiny tomato plants out of little peat pots into bigger ones called "six packs," and were it not for his orange jumpsuit and the corrections officer in the corner, he'd look for all the world like any other gardener in spring.

"You have to be very gentle," Rowan says, slowly lifting the seedlings from one pot into another.

This week, as part of an innovative program called City Harvest, those tomato transplants and thousands of other fruit, vegetable and herb seedlings were to be delivered to 30 community gardens around Philadelphia. There, they will be planted and nurtured, the produce eventually harvested and donated to 30 food cupboards in local churches, community and senior centers, and low-income apartment complexes.

Last year, gardeners donated 12,000 pounds - six tons. This year, mindful of rising food prices and a growing need, they're aiming for 15,000 pounds.

"We all just really like the idea of getting fresh vegetables to community people who are in need of food, particularly a lot of older people who are accustomed to having fresh produce," says Don Nilsen of Powelton Village. Last year, he and four others at the Summer Winter Garden near Drexel University delivered 237 pounds of greens, tomatoes, eggplants and peppers to a food cupboard at a nearby church.

Now in its third season, City Harvest is unusual among prison, community gardening, food-distribution and nutrition-education programs around the country in that it involves not just one or two of those components, but all four.

"For us, there was just tremendous power in that idea," says Priscilla Luce, president of the Albert M. Greenfield Foundation, which has provided $500,000 in grants to see the program through 2009. It's run by Philadelphia Green, the Pennsylvania Horticultural Society's urban-gardening initiative.

The idea came together on several fronts.

First, in the late 1990s, foundations supporting Philadelphia Green began insisting that its community gardens generate "a larger value beyond the aesthetic improvement of one parcel in the city," says Joan M. Reilly, Philadelphia Green senior director.

Several realizations followed: that gardeners were already informally sharing their abundant harvests; that gardening was increasingly being used in "healing workshops" at drug-rehab and other institutions, and that rates for conditions such as obesity and diabetes were going up.

At the same time, the prison system was looking to revive its horticulture program, dormant since an electrical fire destroyed two Victorian-era greenhouses at the State Road complex about a decade ago.

Finally came growing advocacy for "food security," the notion that all households, regardless of income, should have access to enough safely grown, affordable and nutritious food.

Steveanna Wynn, executive director of the nonprofit SHARE, sees it this way: "In some of our city neighborhoods, there aren't any grocery stores. Corner stores don't have fresh produce, and food is so expensive these days, people can't afford it anyway. This is a way to get fresh produce into the diets of people who otherwise literally would not get any."

SHARE, which stands for Self-Help and Resource Exchange, coordinates the distribution of City Harvest produce to food cupboards. The Health Promotion Council of Southeastern Pennsylvania supplies the cupboards with recipes and nutrition information about the produce being given away.

Because of the sluggish economy, Wynn thinks more people than ever will be sharing the harvest this year. "It's ugly, and I'm afraid it's going to get uglier," she says.

Rowan feels good knowing that the Sun Gold and New Girl tomatoes, the habanero and jalapeno peppers, the basil and oregano he's been tending will eventually end up helping local people in need.

"We're feeding the homeless and people in shelters. It's a good deed and a good cause," he says.

Rowan is one of about 12 male and 10 female prisoners who work - in separate groups - inside the greenhouse or outside in the prison's half-acre organic garden. They're low-security inmates, most serving from 30 to 90 days for offenses such as violation of probation or parole, drug use, or failure to pay child support or parking tickets.

Lisa Mosca, a City Harvest instructor, teaches them not just how to grow plants organically, but how to plan next season's crops, manage pests through wise planting, and enrich the soil in the off-season. She also tosses in some basic math, resume-writing and cooking.

"We grow and cook our personal vegetables here, too," Mosca says, pointing to the hoop house next door.

It helps.

"There's no fresh stuff in jail," explains Rowan, whose favorite dish is sauteed broccoli with cheese.

These may not sound like earth-moving life lessons, but corrections officer Tom O'Neal, who started the prison's earlier gardening program and now manages the greenhouse, insists they are.

"Life has not been goal-oriented for these folks," O'Neal says. "They learn about plant propagation, soil structure, a little botany, yes, but it's also about work ethic and broadening horizons."

The prisoners are fascinated by the symbiotic relationships that exist in nature, for example. "They like that aphids are enslaved by ants. We tell them all about it," says O'Neal, who grew up on a dairy farm in Bradford County, Pa.

And so the seasons unfold in a place full of people obsessed with time's passage. Rowan now knows when to sow and transplant, when to plant, water and harvest.

Most important, he knows he might be getting out of here soon. Maybe he'll even do some gardening and cooking when he gets home.

For the moment, he's got tomatoes to move from one pot to the other.

"You can really lose yourself in here," he says.

Contact gardening writer Virginia Smith at 215-854-5720 or vsmith@phillynews.com.