Tumgik
#file under: starter: lorenzo
knotfodder · 7 months
Text
for @cxncordia (for Xandros, from Lorenzo)
Lorenzo pinched at the short length of fabric. The skirt he had been wearing covered less than the panties he had underneath. He wasn't a fan of the color, but more or less liked everything else about the clothes presented to him by Xandros. Along with the short skirt, the faerie was also presented with knee high socks and a crop top that just barley covered his pecs. Lorenzo did appreciate the softness of the clothes he was given, the softest he's ever owned. He gives himself a last look in the mirror before walking into the room where Xandros had been waiting for him. "So how does it look?"
Tumblr media
7 notes · View notes
knotdispenser · 6 months
Text
for @cxncordiaBeltane Starter (Antonio & Lorenzo)
Tumblr media
Lorenzo had walked around the bonfire, scoping out a few fae and others to celebrate Beltane with. It was rare for the fae to take part in celebrations such as these, being far too interested in the mortal world to do so. However, being away from the faerie realms for this long made Lorenzo homesick. It's been a while since his last Beltane celebration and while cautiously moving throughout the crowd around the bonfire, Lorenzo found a man that confused him. He didn't seem like normal fae nor a normal human. The autumn court faerie walks over to him, curiously.
"Happy Beltane! I don't think I've seen you here before, friend. They call me, Lorenzo. What is your name?" He asks with a welcoming smile, hoping to get to know the stranger better.
Tumblr media
7 notes · View notes
tomaspriestley · 3 years
Photo
Tumblr media
➵  BASICS
NAME: Tomas Priestley GOES BY: Tomas, Coffee Maker. AGE / D.O.B: 19th December, 1994. [26 yo] FACECLAIM: Jordan Fisher GENDER & SEXUALITY: Cis-Man, Bi. HOMETOWN: Fort Myers, Florida.  CURRENTLY: Williamsburg, Brooklyn, NYC. AFFILIATION: None. JOB POSITION: Intern for New York Times. EDUCATION: College, Media & Communication Degree.  RELATIONSHIP STATUS: Single. CHILDREN: None.
➵  TRAITS
POSITIVE: Trusting, Fearless, Encouraging, Jovial, Contented. NEGATIVE: Chaotic, Inexperienced, Reckless, Gullible, Impulsive.
➵  BIOGRAPHY
Picturesque is the Priestley household; townhouse in a popular, inexpensive area of Fort Myers, Florida and a kind of family that always wants to be doing something active; moving, running – causing noise; a ruckus; chaos in every avenue. There’s so many of them that it seems impossible to avoid, Alexander and Emilia Priestley liked the idea of a big family from when they were youths and they had secure enough jobs, financials to actually run it without too many hitches. (A hefty inheritance from Emilia’s grandfather in Barcelona that mysteriously left her a sum that seems suspiciously high for a man who appeared as an ordinary businessman, definitely helped with that.) It was nearly every half a decade, there would be a new Priestley child; equally as full of energy as the last.
Tomás was second-born of the Priestley’s, only outranked by his older brother Lorenzo but he never felt like the younger one considering they were all free souls; unrestricted in the sense that they saw their parents one at a time, usually – a twenty four hour shift for their father and an in and out mother who knew more about her current and future court cases that her firstborn’s favourite colour. But, that was OK. They had enough love and devotion between them and it’s almost biological how wild they could be – Tomás could even swear that everyone in Fort Myers knew at least one Priestley.
Throughout all that, the sweet perfection of the family that seemed just as kind behind closed doors as they were out of it, kids boarding down the sidewalks of the beaches, running rampant in coffee shops because there’s more than life than just the rules and the staling of the ordinary. Tomás and Lorenzo noticed it first, when they’d go to bed at night and there’s a sound that’s not so joyous and pleasant coming from their parents room – the arguments that eventually Anna-Maria caught wind of, denied and unsettled the household despite how every morning, the façade is upheld and there’s nothing wrong in the eyes of the Priestley parents when they offer white smiles and hugs at the dinner table; it’s too perfect.
Because it’s not.
And Enzo went off to pursue law at Charleston – just like his mother; made the following in footsteps first and left Tomás in the limbo of how he wasn’t made to be a lawyer; didn’t work well with the mathematics for starters, the eldest brother of the chaotic duo went for the organised route and left the second of them simply wanting to write stories; is the only one absorbing the news from the television on the kitchen side when they’re having breakfast.
The little doodles on the napkins in restaurants at family dinners, the listening ears as he eavesdropped on gossip about the town like he was just there as witness and reporter. He liked it. And it fitted what he wanted – he could see himself doing that, being a writer, editor-in-chief – the dream is there. As it remained to be when he started his final year of school, stayed ever close to his sister Anna-Maria who also, to his quiet approval seemed to want to go into something in the cookery world; open a restaurant; head chef, a kind of left wing decision that whilst he knows his parents would never reject (because they’ve always been taught to pursue dreams) but perhaps doubt in silence.
Except – Tomás realised that when he was a little older, his mother making business trips to Spain, familial things she’d said, were getting increasingly longer, the arguments at least fewer at night. But perhaps, because there was an absence there; a hole in the bubbliness and energy in the townhouse, the bustling of feet barrelling down three flights of stairs is sound forever engrained in the man’s mind.
He misses it.
Because his application for his degree at NYU came back as accepted – as was his internship for the New York Times.
That was both the greatest and worst day of his life.
And not just because it meant moving away from his family and making his own life outside of them. Hanna – one of his younger sisters had been involved in a crash that left her in a coma. Same day, almost the same hour, everything that felt good about that day is clouded in a grey that drowned every single Priestley in seconds as they all found their way to hospital in bursts – dragged out of work, of school and an array of cars that blocked the front entrance for a little longer than helpful just so they could be first there.
Tomás attempted to delay his travel plans to New York, but, like most relentless of business moguls, he was told straight that it would jeopardise not only his college, but his internship and despite extenuating circumstances. Not even his sister in a comatose was a good enough excuse. It broke him – gutted him a little deeper than he wanted when he packed those bags. This time, because his parents had told him to, the same ones that didn’t seem all that enthused about his choices, encouraged him to go for his dreams because that’s what parents did.
Hanna was in the best care, under the best doctors and whether he stayed or left, he couldn’t change a thing.
But it still hurt, and it’s an irony that brings the family closer; they were always relatively tight knit, but one Priestley down means that they all go down, Tomás hates putting his phone down for both business purposes, and in case he ever needs to take that call.
He hopes he never has to.
New York isn’t what he imagined, but like he’s grown up, he’s a little too chaotic – has seen what real trauma is that he won’t let the coffee making and the fact that nobody quite takes him seriously (yet) deter him from achieving his goals. Too enthused to be there, too chaotic in the way he’s leaving doodles on executives desks, sliding along the corridors when he drops paper works on trays and files away in tiny compact rooms barefooted (because, brogues kill his feet) when nobody’s looking and wears the grin like it’s nobody’s business.
Can’t knock the guy down because he’s accustomed to getting back up and getting through it.
➵ HEADCANONS
Fresh coffee splashes over Tomas’ shoes, and from over-stacked hands goes the prints – down into the same spillage that’s soaking his once white socks. Brogues stained and slick with the hot liquid that trickles off fresh lacquer. He’s bug eying the mess that’s right at his feet. Shit, shit, shit lord, fuck. It’s said a hundred times in his head – is still being said even when he’s collecting those brown stained sheets from the floor and hopelessly smacks the papers in some flair of dramatics as thought they’re salvageable. There’s a redness about his cheeks, the late revelation that the print team are looking at him; stifling laughter; disappointed; disgusted mostly – an array of emotions that cross over every possible spectrum of this man is an idiot and reminds Priestley very much how he isn’t equipped for his job, and that getting further seems near unreachable given his one assignment of the day is now smeared and illegible. Thus, the calculations for how much time he has to reprint, rebind and organise a new stack of tomorrow’s article drafts begins; and if he sacrifices dignity of getting out of coffee stained clothes, he might just do it.
A house of noise near enough vibrates the walls of the cramped townhouse, Tomas is running along the downstairs corridors; a child; second eldest of an overflowing family. Loves it; so enjoys his siblings rivalries; all trivial; all playful and a kind of too easy upbringing that makes the Priestley name sounds too much like The Thompson’s, the whole name on the damn letterbox and a front yard that is a little too primp for a three by three that serves as nothing more than aesthetic when it’s practicality doesn’t extend past showing off the ornamental wishing well that sits in the centre. Tomas understands it a little more than his younger siblings, knows what that late night yelling means behind closed doors when everyone else is sleeping. He lies awake at night just listening to the story to be told, stares a little too long at his parents in the morning wearing the perfection masks when making breakfast and that energy of excitement reverberates the house once more. Tomas tries to help – take weight off having seven children in the house, a crazy number to manage in a small place that barely has enough bedrooms with two sharing, but they carried an air that they loved it. That finances were fine; his father as a firefighter and his mother as some hotshot lawyer that a young Tomas doesn’t quite understand just yet – much like how those clashing schedules were never going to work in the long term; stress worn, never shown. And Tomas doesn’t want to do law and he had never been quite heroic enough to be a first responder. His older brother, the favourite for that. He liked to write about it however – stories that were told to engage and passed around scrap papers in the house, those late night rows that he heard become rumours between ever aging siblings; his older brother collecting them and tossing them out before they ever made it back to their parents. Peacekeeper; eventual lawman; proud son of the Priestley’s. Tomas, the intern, doesn’t much compare to that.
Tomas sits in the plastic chair of his Editor’s office, picking at the edge of the armrest as he looks at the cardboard tray holding his boss’ coffee, has said twice already to them that it’s getting cold as if it’s an important detail – breaks the quiet a little more than just feeling this amounting dread that eats away at the man when he waits for his grilling. Priestley has his speech prepared – and it consists of: I swear, boss, I didn’t mean to get the Times barred from Starbucks, I didn’t know it wasn’t a joke when eighty-six orders were given to me, I just thought I was being… nice… It hadn’t just been the excessive order, but the detail that he’d been told about the new drink on the menu: Bean-yonce (you know, the one that definitely does not exist.) and insisted he’d been given that order after being told repeatedly, no, they don’t serve that.
Shoes clack fast on the sidewalk when Tomas is barrelling through the concrete jungle with a pen in hand like a Wildman in the wilderness, text from a friend than tell that there’s a story brewing on 36th street and he’s desperate to get the scoop, wants to at least have something to claim as one of the first on scene – if he makes it in time, only comes close because he’s already nearby. In these moments, thinks about the possibility that this could be the make and break it one; the entry to the big time (whatever that means, changes, depending on the circumstance.) and that his internship at NYT might be taken with a little more severity if he can come back with something that’d be front page news. And sometimes, that desperation crosses into reckless and downright, foolish when he continues to dive headfirst into an emergency responders scene, phone out, pen ready to jot down statements on his goddamn arm if his videoing doesn’t cut it. Nine times out of ten, he’s being dragged out of a firefight; the crossfire and doted luckiest man alive for coming out unscathed and ultimately confused about why he cannot get closer to get the details; the ones that really matter – all whilst grinning like he doesn’t hear the sound of shouting from a neighbouring rooftop that maybe, just maybe, the person he wants to interview might jump before he gets the chance. He then wonders how fast he can climb, definitely, should not find out. 
There’s a little scrawling in the corner of his notebook – a doodle some might say, a little cartoonised character that takes up residence on each little lined paper and acts as a marker for the little flipbook’s Tomas seems to end up creating in the little bursts of time he does have – between work, family and the extra effort put into his job that takes up nearly every waking hour. But he likes to doodle, scribble little stories that match up – or don’t – depends on the day really; a tranquillity that he thinks spurs from his five younger siblings and how keeping them entertained at times can be gruelling; sketching seems like an out to writing the stories where imagery sometimes can denote it in another way. Often leaves little scrap papers around the office of figures waving at editor’s desks and soon removed and labelled annoying when to Tomas it’s a day brightener; because sometimes, New Yorkers need it.
➵  CONNECTIONS
ALEXANDER PRIESTLEY | Father, Fort Myers, Florida. EMILIA PRIESTLEY | Mother, Barcelona, Spain.  LORENZO PRIESTLEY | Brother, 1990, [31 yo] ANNA-MARIA PRIESTLEY | Sister, 1992, [24 yo] HANNA PRIESTLEY | Sister, 2002, [19 yo] CRUZ PRIESTLEY | Brother, 2006, [14 yo, twin] ADAN PRIESTLEY | Brother, 2006 [14 yo, twin] RAMONA PRIESTLEY | Sister, 2013 [7 yo]
➵  WANTED CONNECTIONS
NEW YORK TIMERS [0/?] Bog-standard office connects and all the crazy crackheads that might be running and/or in similar positions, other interns that are with him and all the true madness that any person that throws themselves into shit does. Give me all the dumb HCs.
YOU ARE WHO NOW? [0/2] Tomás is the kind of guy who’d probs like chat up a mafia boss at the damn bar like a bumbling idiot and tell wacky stories about one time, he nearly spilt ice cream on his bosses four thousand dollar suit and lost his job like it might be the CRIME OF THE CENTURY to admit whilst y’know, he’s this irritating thorn in everyone’s side (or amusing lil shit, who knows, maybe they’ll vibe) but regardless, maybe uses/abuses him for his media-ness, heads-up on working stories etc. (despite being an intern) he thinks he’s got SUCH COOL FRIENDS who know everyone and he enjoys bouncing foolhardy stories with them.
COFFEE DEALER [0/1] The kind that ain’t illegal; the person who’s always working the opening shift at the café and he’s always ordering 32 coffees that are that the most ridiculous over the top types of office coffee because he’s the intern and this is clearly, his job. Probably laugh at him, pity him, like him, think he’s crazy for humouring it every morning but this could be fun and quirky.
COP THE STORY [0/2] So, perhaps, that little nosy cop that knows that the intern definitely has loose lips in the sense of he’ll say everything he’s thinking and definitely share things he probably shouldn’t. Also, the cop that’s pulling him out/bailing him away from dangerous situations. Police being second on the scene to Tomás who appears to always be there with a desire for the exclusive; notepad and a pen in hand like some fly on every city wall. Baits him sometimes perhaps and uses him as a stand in; sends a civvie media annoyance into the fray instead of potentially losing a cop? Hm.
I MISSED OUT TO HIM? [0/2] Anyone who knows Tomás will probably be fully aware he’s a literal idiot in the sense that whilst he writes and sells GREAT stories he is pretty hopeless in most every other skill of the world and will probably be out to ruin his chances of progressing past coffee connoisseur and perhaps they applied with him and didn’t get the internship where he did and there’s some unpleasant blood there?
GOVERN-MENTALS [0/1] So, still a work in progress on this one, his mother is a hotshot lawyer and probably has some connections that somehow helped Tomás get somewhere with feet in doors. Possibly a friend of a friend, of a friend or something unlikely that are high up in the government ranks and pushed for him to avoid media and go the law route like some of his other sibling. Possibly some typical prove he’s something to them because his family probably remain sceptical of his choice of path. This leads onto the familial connects.
SCANDALOUS SHENANIGANS [0/1] Give him someone who’s got the scandal of the century, he’s stumbled upon it and has no idea what to do with the information. Doesn’t know who deserves to be presented with it; whether he’s got to fight for credit to get his name on it. Whether he’s blackmailed to keep quiet; paid off; a complicated thing that could get spicy and messy.
➵  QUICK LINKS
THREADS
MUSINGS
HEADCANONS
SELF-PARAS
0 notes
affectos · 7 years
Text
Slipstream
So, I wanted to find a unique way for Lorenzo to become part of Overwatch, and I’ve had this scene of Lorenzo and Tracer avoiding collision with each other (Tracer jumping over, Lorenzo sliding under) and they meet eyes.  That’s where this story came from
   Lorenzo knew Talon was moving in on him.  
   Shoving his few belongs into his bag, he glanced out the window of his shabby motel room out into the downpour that was falling over Kings Row.  He sighed; he hated getting his leg prosthetics wet.  The former Formula One and MotoGP racer had been on the run for...had it already been three weeks now?  When you’re hunted by an evil terrorist group, survival comes before checking the day of the week.
   Flicking of the lights in his room, Lorenzo grabbed the SMG he picked up prior to leaving Italy and slung the strap over his shoulder.  Taking his travel bag, he took a deep breath and opened the door leading out of the motel and sprinted off into the torrential rain.
   ‘To think that this all started over an engine design...’ Lorenzo thought as the rain pelted his face with each step.  During his off-season of the MotorGP, he’d been approached by a team of mechanical engineers to be the test driver for an experimental engine.  He was assured that he’d be safe and that the engine would pose no threat to him and that if it was successful, he’d be advancing technology for years to come.
    He wasn’t allowed to see or inquire too much about the engine, however what he did know is that the engine handled like nothing he’d ever driven before.  It was smooth shifting and transitions between gears, yet at the same time, there what felt like an uncontrolled energy that was barely held in check.  Lorenzo knew that if this got brought to racing, it’d take the sport to a whole new level.  However, there were some people who had other plans for the engine.
   Sprinting down an alley, Lorenzo remembered that there was one day after a day of intense testing that a few of the scientists were arguing with a man that he could only describe as a high-ranking soldier.  They hushed as Lorenzo approached, so he didn’t know what they were fiercely fighting over, but before the soldier left, he said said that the scientists only had 24 hours left.  Whoever this guy was, it had put serious fear into the scientists, enough that they told Lorenzo to take the rest of the day off.
   The next day, just walking in and approaching the scientists, Lorenzo knew that something just felt off.  For starters, the engineers who usually were talking in enthusiastic hushed voices about how to improve the engine were silent and more on edge, constantly scanning the exits.  There was almost no small talk that day, instead they just had him do time trials.  Even the bike felt off.  Whatever that had been giving it the smooth yet barely constrained feel was gone, but rather it felt like a normal motorbike.
   ‘Turned out their paranoia was justified,’ he ran up a set of steps as he recalled what happened next.
   He’d finished the time trials and was coming back from a break when he saw the dropship land at the test track.  From where he stood, he watched as a group of soldiers poured out.  Some attacked the scientists and engineers who tried to flee while the others started to gather up the equipment from the site.
   Lorenzo didn’t need to be told to run.  He bolted out of the test facility, only to have a few soldiers realize that they’d let one person escape.  He tried to hide out at home, but they were able to track him down; he considered contacting the authorities, but feared that they weren’t enough; he decided his only option was to run.  Withdrawing a portion of his money, he put his bike in storage and fled Italy.
   It wasn’t until a week in that he learned why the group called Talon was after him.  He was doing a weekly digital diagnostics on his leg prosthetics and found a file that hadn’t been there previously.  Opening it, he found that they were schematics for a tachyon-driven engine, more than likely the one that he had been testing.
   The only time he could think that the files could’ve been placed in his legs could’ve been the day the higher-ranked soldier had intimidated the engineers.  He’d been in the showers prior to walking in on them, and he always left his prosthetics out of the way of water.  One of the scientists could’ve easily uploaded the schematics without anyone knowing.
  ‘And here I am today, still on the run, public thinking I’m missing, and running out of luck.’
  Emily wasn’t going to be happy that they had to end movie night early.
   Lena Oxton, AKA Tracer, had gotten the call from Overwatch’s Omnic AI Athena, asking for a favor.  Talon soldiers had been spotted in King’s Row and as she was the closest, if she could investigate.
   “Any updates Athena?” Tracer asked into her com as she blinked through the sparsely crowded streets towards where they’d last been seen.
   “I have reports of Talon agents raiding a motel at St. Chad’s Place.” the female AI replied, causing Tracer to adjust her route to take here there, “Moreover, I’ve found a pattern of similar raids across Europe, going back three weeks.  It’s my belief that Talon is chasing someone, so be advised in case you come across them.”
   Tracer chuckled to herself as she splashed through the storm, ‘Not often that someone is able to give Talon a run for their money.  Only people I can think of are myself, Winston, and other Overwatch agents from back in the day.  This new guy might be worth recruiting...’
   Taking a corner and blinking ahead, Tracer’s attention was pulled by a sudden spotlight sweeping across a side streets as she passed it.  She didn’t focus on it for too long, for if she had, she would’ve for certain collided with the figure running full blast at her.
   It was almost as if the two of them were in sync, for as Tracer went to try to jump over him, the mystery person slid under her.  Rolling as she hit the ground, she managed to regain her footing and looked back at the person who almost ran her down. He too had slid to a stop, surprised at the person who he had almost literally ran into.  
   Taking in the appearances, she noted most notably that he had two prosthetic legs.  Beyond that, he appeared to be wearing some form of zip-up jumpsuit, similar to what she wore when she was in Overwatch’s flight program, but his was more vibrant.  His face showed exhaustion and a bit of fear, but mainly desperation lit his eyes.  His hand was gripping the handle of his firearm, but his finger was nowhere near the trigger, hesitating.
   ‘This...this must be the guy Talon is after...’    
   Honestly, Lorenzo was not expecting this.  Sliding to a halt on the wet sidewalk, he whipped his head back at the woman, his hand on his gun, yet...he couldn’t bring himself to fire.  Clearly the woman wasn’t from Talon, she’d come from the complete opposite direction that Talon was; not to mention her outfit was drastically different.  He could swear that he’d seen her somewhere else before, but he didn’t have time right now to dig that information up.  He knew that Talon was hot on his footsteps, and this woman essentially was his only chance to get out of the situation alive.
   Letting go of the handle of his SMG, he looked straight into the woman’s eyes, and with a steady, yet pleading voice simply said, “Help me.”
   There was a bit of silence between them as Lorenzo held his breath, waiting for an answer.  The woman blinked at this before slowly getting up, bushing the mud off her leggings and jacket, “So, you must be the one giving Talon the slip.”  Hustling over to him, the woman offered a hand, which Lorenzo took and pulled himself up, “Now, let’s get you somewhere safe.”
 There was a flash of blue next to Lorenzo, causing him to shield his eyes a bit.  Once the light was gone, he noticed that the woman was missing.
   “Over here!” Lorenzo whipped his head to the voice to see the woman standing down the street from him, “Come on, you can tell me why you’re such a wanted man on the way!”
   Taking a deep breath, Lorenzo pushed off again, running to catch up with her.  He wasn’t exactly in the mood to question the possibility of a teleporting woman right now, so he didn’t argue.
   Once aside her, the woman sprinted off, leading him through alleyways and side streets, “So, what’s your name luv?” she asked as they wove through an alley with trash cans and dumpsters.
   “Lorenzo Trazione.” Lorenzo replied jumping a pile of trash bags, “What about you?  I swear I’ve seen you before...”
   The woman giggled, “Not surprised with Overwatch re-forming and all.  Lena Oxton, but my friends call me Tracer.”  Lorenzo then realized why she was familiar, Tracer had been the poster-child of the reformed Overwatch Initiative. He was running with an icon.
   As they reached the entrance to an abandoned Underground station, Tracer glanced back to him, “So, what did you do to get the attention of Talon?  They don’t hunt down just anyone.”
   Lorenzo nodded and gestured to his legs as they headed down into the coldly lit tile stairwell, “I’m the last of a team that worked on some kind of experimental engine.  I was only the tester, so I don’t know much about it, but I know that it runs on tachyons?”
   Tracers came to a stop, mainly due to the tall gate that was designed to keep out trespassers, but also at the word ‘tachyon’.  Glancing over her shoulder, she gave him a smile, “I think I know just the man who could take a look at that, but first...” She looked back at the gate, took a few steps back, then sprinted and jumped.  A bit off the ground, Tracer blinked up to the top of the gate where she pulled herself through a gap at the top before landing on the other side.  Looking through the gate she pulled out one of her Pulse Pistols, “I could shoot the lock off, but it might be noisy.”    Lorenzo shook his head, “I’ve gotten good at jumping fences in the last few weeks.”  Lorenzo also took a few steps back before running full blast at the fence.  Right before hitting the wall, he crouched and pushed up, launching himself to the gap, grabbing the edge and using the momentum to pull himself over and dropping down.
   The Brit smiled, “I’m impressed luv, not many people can keep up with me.  Now come on, Talon isn’t likely to search the Underground.”
  Emily leaned against the counter in the small flat that she and her girlfriend Lena owned.  Sure, she was miffed that Overwatch business had interrupted their movie night, but she understood that it was for the greater good.  While her girlfriend was out saving the world, Emily knew it was her job to prepare a batch of cocoa fo when Lena arrived home.
   As she placed the kettle on the stove, Emily heard the telltale sound of her girlfriend’s Blinking up to the door of their mat. As the door opened, Emily pulled out two mugs and headed into the living room to greet Lena, “That was faster than I thought.  Cocoa’s on the stove and the movie is still pau-”
   She stopped mid sentence as she saw Lena and a mystery man, both soaked to the bone, standing on the hall mat, dripping onto the floor, the male looking exhausted as he leaned on the doorframe for support.
   “I think we’re going to need a third mug Emily...” Tracer sheepishly said, “We’re going to be having a guest overnight.”
2 notes · View notes
leblognoir-blog · 5 years
Text
LAKES, MOUNTAIN VILLAGES, AND HIKING
Ticino is a very special place: it mixes breathtaking Swiss mountain scenery with everyone’s favorites from the Italian cuisine. Could there be a better place on earth?
If you wouldn’t know, you might think you’d be in Italy rather than in Switzerland. The southernmost canton of the Swiss Confederation, Ticino, doesn’t only border on Italy, but their official language is also Italian. The same goes for the ‘Tessin cuisine’: their pizze, pasta, gelato, expresso, … is just as delicious as in Italy. Add some beautiful lakes and the Swiss Alps in the background and you have the perfect travel destination.
Here’s a few highlights of our week in Ticino:
Hiking
There are endless hiking options in Ticino, which will make any mountain hiker happy: lush green valleys, homely hamlets with Romanesque chapels, roaring mountain streams, overlooking lakes Maggiore and Lugano; always covered under the cool shade of the many chestnut trees. The hiking trails are excellently well-signposted.
A good starting point with free parking is e.g. the hamlet Cademario, near the bus stop “Lisone”.
The very mild climate, compared to the rest of Switzerland, makes hiking extra enjoyable: they have 2,300 sunshine hours every year in Ticino!
Lugano
Lugano is the largest city in Ticino and the biggest town on lake Lugano. I not only loved its Italian architecture (think pastel-colored mansions along cobblestone streets!), but of course the many piazzas with restaurants and cafés. It’s definitely the best place to have an afternoon espresso or gelato and just taking it all in. The main piazza of Lugano is Piazza della Riforma (pictured above).
For starters, and especially if you arrive by train or bus, take the funicular from the train station down to the center (look for signs that guide you to the railway).
Not to be missed in Lugano are also its magnificent churches with remarkable frescos, like e.g. Cathedral di San Lorenzo from the early 16th century, or Chiesa di Santa Maria degli Angioli.
Another highlight is for sure strolling along the flowery, palm fringed promenade on Lake Lugano; from the water jet on the bay of Lugano and the fountain “Fontana dell’Acquaiola” in the Paradiso neighborhood, all the way to the Lungolago gardens with its beautiful park “Parco Civico” (“Parco Ciani”).
Look out for red Vespas scooting along!
Lago di Lugano
This mirror-like Alpine lake is mystically surrounded by steep tree-covered mountains. Admire Lake Lugano from a mountain hike, a stroll along the beautiful lakeside promenade in Lugano, or on the lake itself: Boat rides are available from Lugano’s Piazza della Reforma, or rent a pedal boat for 30 minutes, like we did!
Bellinzona
Bellinzona is a medieval fortress town, hosting three grey-stone castles: Castelgrande, Castello di Montebello, and Castello di Sasso Corbaro.
The main castle of the trio, and the closest to the city, is Castelgrande, which is build on a rocky hill above the Old Town. You can easily walk up to the castle from Piazza Collegiata (head up the stairs of Salita San Michele) – there are several signs along the way. Simply enjoy the views of the Old Town and Alps, or have a look into the museum.
On Piazza Collegiata you cannot not notice the huge front of the Renaissance church (Chiesa) Collegiata dei SS Pietro e Stefano: its frescos and baroque stucco will leave you breathless while entering the building.
Churches
70% of the Ticino population is Catholic, and there are a lot of stunning churches to visit. You actually cannot miss them while in Ticino: They are very present in the towns of Lugano and Bellinzona, and there are many churches (“chiese”) as well as little chapels (“cappelle”) in the mountain villages.
Food
Local cuisine is found in the so-called “Grottos”: rustic restaurants with tables romantically set up under the area’s famous chestnut trees.
Ticino’s top speciality is most certainly “Polenta”, a dish of savoury boiled cornmeal, served in various forms (e.g. creamy, baked, fried, or grilled). Home made pizza and pasta is of course also always a very good idea while dining in Ticino. Personally, I love my Italian food as basic as possible, to not get too distracted by a lot of ingredients. Home-made gnocchi with butter and sage, or a simple Pizza Marinara with only tomato sauce, oregano, and garlic are sooo so good in Ticino.
Local Ticinese meals are usually accompanied by their Merlot – red or white! For non-alcoholic drinks, opt for their famous lemonade “Gazzosa Ticinese”, that comes in flip-top glass bottles.
Arrivederci and enjoy Ticino! Share your travel experiences in the comments if you’d like!
I hope you enjoy reading my blog – if you do, please consider supporting le blog noir. Thank you! ♥
  [new blogpost] A Quick Trip to Ticino, Switzerland #ticino #switzerland #visitswitzerland #quicktrip #switzerlandtourism #swiss #italian #europetrip #in_europe #ticinotweets LAKES, MOUNTAIN VILLAGES, AND HIKING Ticino is a very special place: it mixes breathtaking Swiss mountain scenery with everyone's favorites from the Italian cuisine.
0 notes
six meals for each shipment
It to our advantage. So I want you to play, and if he taking advantage of your teammates, that something you can address when the time arises.wholesalejerseyslan First shift, they send Howe out there and he wants to fight and I said no to Yannick. Clay Buchholz (4 0) allowed eight hits in eight innings, struck out six and walked one. Andrew Bailey allowed Lorenzo Cain's leadoff homer over the Green Monster in the ninth, his fourth hit of the game, then got his third save when Alex Gordon hit a game ending groundout with two on. Shields gave up one run and four hits in six innings with eight strikeouts and three walks. Cheap Jerseys from china Blue Apron's meals cost less than $10 each. The meals at HelloFresh and Plated are a couple of dollars more, but you can lower the price if you buy more meals per shipment or opt for the vegetarian meals from HelloFresh. While the companies tout the per meal price, Blue Apron and HelloFresh require buying a minimum of six meals for each shipment.Cheap Jerseys from china Adidas meanwhile, has also introduced a technology called Adizero. The Adizero technology, which was earlier used by Adidas in their F50 line of football shoes, is now a part of the players' kits. The Adizero technology was used to reduce the weight of the shoe. Cheap Jerseys free shipping Wildie recalled a game against Mesick his senior year where the yard lines were the only part of the field plowed. In between was about a half foot of snow. A Michigan State graduate, Wildie lives on Platte Lake following a career working as a pesticide specialist for the state of Michigan and then working in cabinetry..Cheap Jerseys free shipping cheap nfl jerseys Buying presents for birthdays, Christmases and other special occasions can really stretch your imagination too far, and sometimes you run out of ideas. The best way to find the best gift for someone https://www.wholesalejerseyslan.com is to get to know his hobby or favorite sport, then purchase something related to that sport or hobby. If the receiver of your gift is a cycling enthusiast, then buying him a bicycling jersey as a gift is a good idea..cheap nfl jerseys cheap jerseys 1896, from committee to the full House for consideration. 1896, has languished in the House Labor and Industry Committee since it was introduced in December because of the refusal by House Republicans to even bring the bill up for debate. Senate to bring a federal minimum wage bill up for a vote..cheap jerseys George Washington, who later became the cheap nfl jerseys http://cheapjerseys30.blogspot.com/2018/05/a-misdemeanor-under-federal-law.html new nation's first President, crossed the Delaware River from Pennsylvania to Trenton, New Jersey, with the Continental Army. He turned the tide of the war by defeating the Hessians. Some soldiers' wives went along as camp followers, but others remained home and took on all the work required to keep his occupation going.. According to a complaint filed by teacher Yolanda Pandolfi Hopkins, Roosevelt Elementary School Principal Donna Ronzone "singles out Latino parents to determine whether their children met the residency requirements to attend Roosevelt. Some Latino families have had to meet with Ronzone as many as four times to prove their children are allowed to attend Roosevelt," the allegation being that Ronzone is trying to keep her test scores high. Since she took over, the school's API (academic performance index) score based on a scale of 1,000, where 800 is considered proficient has hovered in the mid 800s and this year the school exited Program Improvement status.. cheap jerseys True to form for the brand, the styling is evolutionary and perhaps even loses a little of the drama of the Mk1 model although it's a much improved car in every way.To push it even closer to its Lamborghini Huracan stablemate, V8 power has been dropped leaving the V10 only, in two outputs: 533bhp or 602bhp. The car is automatic only, too, although a manual gearbox may be offered later if demand is there; the gated manual box was one of the original R8's real highlights.The higher powered V10 Plus is a true supercar, giving 0 62mph in 3.2 seconds and hitting 205mph. Even the 'base' model completes the benchmark in 3.5 seconds.cheap jerseys Cheap Jerseys china I walked past Ken Griffey Jr.'s parents and family coming out of a room into a long hallway near the entrance to the field and thought of photographing dignitaries walking around long corridors in the West Wing. I decided it wasn't really a good paparazzi moment and figured getting established on the field was more important. After all, I was the new guy and really didn't know what I was doing.Cheap Jerseys china wholesale jerseys It wasn until B Real and Chuck D unveiled the refurbished lyrics of Rage Against the Machine signature cut, in the Name, that the whole thing went nuclear. Of those who hold office are the same who burn crosses, they chanted, accusing the president of being a white supremacist. Then the song ended, and because the Prophets had a brand new record to sell, B Real closed the show with a call to action: the f album! Get the f album! Is that all 21st century protest music wants us to do Reach for our debit cards.wholesale jerseys A dazzling game by McDavid but overshadowed by Auston Matthews four goals in his first NHL game for the Maple Leafs. My first game, I think I only touched the puck four times. Little bit different night for us. Leaving Jonathan Bernier, supposedly a prized prospect and 2010 AHL goalie of the year in a backup position, with a team that likely has their starter for the next decade. Well don't you think Brodeur would be a great mentor for the young Bernier With one season remaining on Brodeur's deal the 2011 2012 season could represent a passing of the torch in goal for the Devils and one in which Brodeur and Bernier split time in goal with the hopes that Bernier proves to be a full fledged number one. And even more convenient, Hedberg is a UFA at the end of this season.. wholesale nfl jerseys 3, 2016. The National Hurricane Center says Tropical Storm Hermine could bring 4 to 7 inches of rain to southeastern Virginia and the Atlantic coastal portion of Maryland as well as 1 to 4 inches of rain over southern Delaware, southern and eastern New Jersey and Long Island through Monday morning. (Stephen M.wholesale nfl jerseys wholesale jerseys from china Vick played college football at Virginia Tech, where as a freshman he placed third in the Heisman Trophy balloting. He left after his sophomore year to enter the NFL and was drafted first overall by the Atlanta Falcons in the 2001 NFL Draft, the first African American quarterback ever taken in that position. In six seasons with the Falcons, he gained wide popularity for his performance on the field, and led the Falcons to the playoffs twice wholesale jerseys from china. ...
0 notes
iyarpage · 7 years
Text
Carthage Tutorial: Getting Started
Update note: This tutorial was updated to iOS 11, Xcode 9, and Swift 4 by Lorenzo Boaro. The original tutorial was written by James Frost.
Learn how to use Carthage to manage your project’s dependencies.
Two great things about iOS development are the fantastic community, and the wide range of available third party libraries.
If you’ve coded on the platform for a while, chances are you’ve used at least one of these libraries. Whether it’s Alamofire, Locksmith, or Kingfisher, you already know the value of making use of someone else’s code because you’re not fond of reinventing the wheel.
Then there’s CocoaPods. If you’re not acquainted with this lovely tool, it’s a popular dependency manager that streamlines the process of integrating these sorts of libraries into your project.
It’s widely used in the iOS community, and even Google uses it to distribute their various iOS SDKs.
Alongside Swift 3.0, Apple has released its own tool called Swift Package Manager to share and distribute packages in Swift 3.0 and above. Apple defines it as:
The Swift Package Manager is a tool for managing the distribution of Swift code. It’s integrated with the Swift build system to automate the process of downloading, compiling, and linking dependencies.
While CocoaPods and Swift Package Manager are awesome, there are other options. Carthage is one such alternative; it’s a ruthlessly simple dependency manager for macOS and iOS, created by a group of developers from Github.
It was the first dependency manager to work with Swift; in fact, Carthage itself is written in Swift! It exclusively uses dynamic frameworks instead of static libraries – this is the only way to distribute Swift binaries that are supported by iOS 8 and up.
In this Carthage tutorial, you’ll learn and do the following:
Why and when to use a dependency manager, and what makes Carthage different
How to install Carthage
How to declare dependencies, installing and integrating them within a project
How to upgrade your dependencies to different versions
Build an app that provides definitions for search terms using the DuckDuckGo API
Note: This Carthage tutorial assumes that you have basic familiarity with iOS and Swift, that you’re familiar with Xcode and working with the command line.
If you need to brush up on any of these topics, check out some of our other written or video tutorials on this site.
Getting Started
First of all, download the starter project for this Carthage tutorial.
It includes the basic skeleton of DuckDuckDefine, a simple tool to look up definitions and images using the DuckDuckGo API. There’s just one problem: It doesn’t actually perform any searches yet!
Open DuckDuckDefine.xcodeproj in Xcode and have a quick look around to familiarize yourself. Note the two view controllers: SearchViewController provides a search bar for the user to perform a search, and DefinitionViewController displays the definition of a search term.
The brains of the operation are in DuckDuckGo.swift — or at least they will be by the time you’re finished! At the moment, performSearch(for:completion:) is a lazy, good-for-nothing block of code.
To make it perform a search and display the results, you’ll need to do two things:
Make a query using the DuckDuckGo API
Show an image for the retrieved word
There are a number of open source libraries that can help with these two tasks. Alamofire is a great Swift library which simplifies making web requests, and AlamofireImage makes dealing with images in Swift a more pleasant experience.
And guess what? You’ll use Carthage to add both of these dependencies to your project.
Dependency Management
To add Alamofire and AlamofireImage to your project, you could of course just visit their respective Github pages, download a zip file of the source and drop them into your project. So why bother with a tool like Carthage?
Dependency managers perform a number of handy functions:
They simplify and standardize the process of fetching third party code and incorporating it into your project. Without such a tool, this might be done by manually copying source code files, dropping in precompiled binaries, or using a mechanism like Git submodules.
They make it easier to update third party libraries in the future. Imagine having to visit each dependency’s GitHub page, download the source, and place it into your project every time there’s an update. Why would you do that to yourself?
They pick out appropriate and compatible versions of each dependency you use. For instance, if you’re manually adding dependencies, things can get tricky when they depend on one another or share another dependency.
Most dependency managers will construct a dependency graph of your project’s dependencies, and each of their sub-dependencies, and then determine the best version of each to use.
You could probably do the same manually, but at what cost? Your sanity?
Carthage vs CocoaPods
So how exactly is Carthage different from CocoaPods, and why would you use anything besides the most popular dependency manager for iOS?
Carthage’s developers felt that whilst CocoaPods is generally easy to use, simple it is not. The philosophy behind Carthage is that this tool should be ruthlessly simple.
CocoaPods adds complexity to both the app development and the library distribution processes:
Libraries must create, update and host Podspec files (or app developers must write their own if one doesn’t exist for a library that they wish to use).
When adding “pods” to a project, CocoaPods creates a new Xcode project with a target for each individual pod, as well as a containing workspace. Then you have to use the workspace and trust that the CocoaPods project works correctly. Talk about a lot of extra build settings to maintain.
CocoaPods’ Podspecs repository is centralized, which could be problematic if for some reason it were to disappear or become inaccessible.
The Carthage project’s aim is to provide a simpler tool than CocoaPods; one that’s easier to understand, easier to maintain and more flexible.
It achieves this in a number of ways:
Carthage doesn’t modify your Xcode project or force you to use a workspace.
There’s no need for Podspecs or a centralized repository for library authors to submit their pods to. If your project can be built as a framework, it can be used with Carthage. It leverages existing information straight from Git and Xcode.
Carthage doesn’t really do anything magic; you’re always in control. You manually add dependencies to your Xcode project and Carthage fetches and builds them.
Note: Carthage uses dynamic frameworks to achieve its simplicity. This means your project must support iOS 8 or later.
Carthage vs Swift Package Manager
How about the differences between Carthage and Swift Package Manager?
The main focus of the Swift Package Manager is to share Swift code in a developer-friendly way. Carthage’s focus is to share dynamic frameworks. Dynamic frameworks are a superset of Swift packages since they may contain Swift code, Objective-C code, non-code assets (e.g. images) or any combinations of the three.
Note: A package is a collection of Swift source files plus a manifest file. The manifest file defines the package’s name and its content.
Installing Carthage
Now that you’ve got some background on things, that’s enough talk. It’s time to learn for yourself how ruthlessly simple Carthage is!
At the core of Carthage is a command line tool that assists with fetching and building dependencies.
There are two ways to install it: downloading and running a .pkg installer for the latest release, or using the Homebrew package manager. In the same way that Carthage helps install packages for your Cocoa development, Homebrew helps install useful Unix tools for MacOS.
For the purposes of this Carthage tutorial, you’ll use the .pkg installer. Download the latest release of Carthage from the list here. Select the most recent build, then under Downloads select Carthage.pkg.
Double-click Carthage.pkg to run the installer. Click Continue, select a location to install to, click Continue again, and finally click Install.
Note: When you attempt to run the installer, you may see a message stating “Carthage.pkg can’t be opened because it is from an unidentified developer.” If so, Control-click the installer and choose Open from the context menu.
And you’re done! To check that Carthage installed correctly, open Terminal and run the following command:
carthage version
If all has gone to plan, you’ll see the version number of Carthage that was installed.
Note: At the time of writing, the current version of Carthage was 0.23.
Next, you need to tell Carthage which libraries to install. This is done with a Cartfile.
Creating Your First Cartfile
A Cartfile is a simple text file that describes your project’s dependencies to Carthage, so it can determine what to install. Each line in a Cartfile states where to fetch a dependency from, the name of the dependency, and optionally, which version of the dependency to use. A Cartfile is the equivalent of a CocoaPods Podfile.
Navigate to the root directory of your project in Terminal (the directory that contains your .xcodeproj file) using the cd command:
cd ~/Path/To/Starter/Project
Create an empty Cartfile with the touch command:
touch Cartfile
And then open the file up in Xcode for editing:
open -a Xcode Cartfile
If you’re familiar with another text editor, like Vim, then feel free to use that instead. Don’t, however, use TextEdit to edit the file; with TextEdit it’s too easy to accidentally use so-called “smart quotes” instead of straight quotes, and they will confuse Carthage.
Add the following lines to the Cartfile and save it:
github "Alamofire/Alamofire" == 4.5 github "Alamofire/AlamofireImage" ~> 3.2
These two lines tell Carthage that your project requires Alamofire version 4.5, and the latest version of AlamofireImage that’s compatible with version 3.2.
The Cartfile Format
Cartfiles are written in a subset of OGDL: Ordered Graph Data Language. It sounds fancy, but it’s really quite simple. There are two key pieces of information on each line of a Cartfile:
Dependency origin: This tells Carthage where to fetch a dependency from. Carthage supports two types of origins:
github for Github-hosted projects (the clue’s in the name!). You specify a Github project in the Username/ProjectName format, just as you did with the Cartfile above.
git for generic Git repositories hosted elsewhere. The git keyword is followed by the path to the git repository, whether that’s a remote URL using git://, http://, or ssh://, or a local path to a git repository on your development machine.
Dependency Version: This is how you tell Carthage which version of a dependency you’d like to use. There are a number of options at your disposal, depending on how specific you want to be:
== 1.0 means “Use exactly version 1.0”
>= 1.0 means “Use version 1.0 or higher”
~> 1.0 means “Use any version that’s compatible with 1.0″, essentially meaning any version up until the next major release.
If you specify ~> 1.7.5, then any version from 1.7.5 up to, but not including 2.0, is considered compatible.
Likewise, if you specify ~> 2.0 then Carthage will use a version 2.0 or later, but less than 3.0.
Compatibility is based on Semantic Versioning – for more information check out our tutorial on Using CocoaPods with Swift.
branch name / tag name / commit name means “Use this specific git branch / tag / commit”. For example, you could specify master, or a commit has like 5c8a74a.
If you don’t specify a version, then Carthage will just use the latest version that’s compatible with your other dependencies. You can see examples of each of these options in practice in Carthage’s README file.
Building Dependencies
So now you have a Cartfile, it’s time to put it to use and actually install some dependencies!
Note:This Carthage tutorial uses Swift 4, and at the time of this Carthage tutorial, Swift 4 is only available in Xcode 9. Ensure that your command line tools are configured to use Xcode 9. Run the following command from Terminal:
sudo xcode-select -s <path to Xcode 9 beta>/http://ift.tt/1FBGujK
Be sure to replace path to Xcode 9 beta with your machine’s specific path to Xcode 9.
Close your Cartfile in Xcode and head back to Terminal. Run the following command:
carthage update --platform iOS
This instructs Carthage to clone the Git repositories that are specified in the Cartfile, and then build each dependency into a framework. You should see output that shows what happened, similar to this:
*** Fetching AlamofireImage *** Fetching Alamofire *** Checking out Alamofire at "4.5.0" *** Checking out AlamofireImage at "3.2.0" *** xcodebuild output can be found in /var/folders/cn/tknd724s0fv8pbdcbkg2sb6w0000gn/T/carthage-xcodebuild.no8ytB.log *** Building scheme "Alamofire iOS" in Alamofire.xcworkspace *** Building scheme "AlamofireImage iOS" in AlamofireImage.xcworkspace
The --platform iOS option ensures that frameworks are only built for iOS. If you don’t specify a platform, then by default Carthage will build frameworks for all platforms (often both Mac and iOS) supported by the library.
If you’d like to take a look at further options available, you can run carthage help update.
By default, Carthage will perform its checkouts and builds in a new directory named Carthage in the same location as your Cartfile. Open up this directory now by running:
open Carthage
You should see a Finder window pop up that contains two directories: Build and Checkouts. Take a moment to see what Carthage created for you.
Build Artifacts
If you’re familiar with CocoaPods, you know that it makes a number of changes to your Xcode project and binds it together with a special Pods project into an Xcode workspace.
Carthage is a little different. It simply checks out the code for your dependencies, builds it into binary frameworks, and then it’s up to you to integrate it into your project. It sounds like extra work, but it’s beneficial. It only takes a few steps and you’ll be more cognizant of the changes to your project as a result.
When you run carthage update, Carthage creates a couple of files and directories for you:
Cartfile.resolved: This file is created to serve as a companion to the Cartfile. It defines exactly which versions of your dependencies Carthage selected for installation. It’s strongly recommended to commit this file to your version control repository, because its presence ensures that other developers can get started quickly by using exactly the same versions of dependencies as you.
Carthage directory, containing two subdirectories:
Build: This contains the built framework for each dependency. These can be integrated into your project, which you’ll do shortly. Each framework is either built from source, or downloaded from the project’s “Releases” page on Github.
Checkouts: This is where Carthage checks out the source code for each dependency that’s ready to build into frameworks. Carthage maintains its own internal cache of dependency repositories, so it doesn’t have to clone the same source multiple times for different projects.
Whether you commit the Build and Checkouts directories to your version control repository is entirely up to you. It’s not required, but doing so means that anybody who clones your repository will always have the binaries and source for each dependency available.
Having this backup can be a useful insurance policy if, for example, Github is unavailable or a source repository is removed completely.
Don’t modify any code inside the Checkouts folder because its contents may be overwritten at any time by a future carthage update or carthage checkout command, and your hard work would be gone in the twinkling of an eye.
If modifications to your dependencies are a must do, you can run carthage update using the --use-submodules option.
With this option, Carthage adds each dependency in the Checkouts folder to your Git repository as a submodule, meaning you can change the dependencies’ source, and commit and push those changes elsewhere without fear of an overwrite.
Note: If other users need to use your project, and you haven’t committed the built frameworks with your code, then they will need to run carthage bootstrap after checking out your project.
The bootstrap command will download and build the exact versions of your dependencies that are specified in Cartfile.resolved.
carthage update, on the other hand, would update the project to use the newest compatible versions of each dependency, which may not be desirable.
Now, how about actually using these build artifacts you worked so hard to create?
Adding Frameworks to Your Project
Back in Xcode, click the DuckDuckDefine project in the Project Navigator. Select the DuckDuckDefine target, choose the General tab at the top, and scroll down to the Linked Frameworks and Libraries section at the bottom.
In the Carthage Finder window, navigate into Build\iOS. Drag both Alamofire.framework and AlamofireImage.framework into the Linked Frameworks and Libraries section in Xcode:
This tells Xcode to link your app to these frameworks, allowing you to make use of them in your own code.
Next, switch over to Build Phases and add a new Run Script build phase by clicking the + in the top left of the editor. Add the following command:
/usr/local/bin/carthage copy-frameworks
Click the + under Input Files and add an entry for each framework:
$(SRCROOT)/Carthage/Build/iOS/Alamofire.framework $(SRCROOT)/Carthage/Build/iOS/AlamofireImage.framework
The result should look like this:
Strictly speaking, this build phase isn’t required for your project to run. However, it’s a slick workaround for an App Store submission bug where apps with frameworks that contain binary images for the iOS simulator are automatically rejected.
The carthage copy-frameworks command strips out these extra architectures. w00t!
There won’t be anything new to see yet, but build and run the app to ensure everything’s still working as expected. When the app launches, you should see the search view controller.
OK, great. Things are looking good. Next, upgrading dependencies.
Upgrading Frameworks
I have a confession to make.
Remember when you created your Cartfile earlier, and I told you what versions of Alamofire and AlamofireImage to install? Well, you see, I gave you bad information. I told you to use an old version of Alamofire.
Don’t be mad though! It was done with the best of intentions. Look on this as an opportunity…yes, an opportunity to learn how to upgrade a dependency. It’s a gift, really.
Open up your Cartfile again. From your project’s directory in Terminal, run:
open -a Xcode Cartfile
Change the Alamofire line to:
github "Alamofire/Alamofire" ~> 4.5.0
As you saw earlier, this means to use any version of Alamofire that’s compatible with 4.5.0, so, any version up to but not including a future 5.0 version.
When adding dependencies with Carthage, it’s a good idea to consider compatibility and limit the version that you’re targeting. That way, you know the exact state of its API and functionality.
For example, version 5.0 of a dependency might include app-breaking API changes — you likely wouldn’t want to automatically upgrade to it if you built your project against 4.5.0.
Save and close the Cartfile, and return to the terminal. Perform another update:
carthage update --platform iOS
Carthage will look for newer versions of each of your dependencies, then check them out and build them if necessary. You should see it fetch the latest version of Alamofire.
Because your project already contains a reference to the built .framework for Alamofire, and Carthage rebuilds the new version in the same location on disk, you can sit back and let Carthage do the work; your project will automatically use the latest version of Alamofire!
Duck, Duck… GO!
Now that you’ve integrated Alamofire and AlamofireImage with the project, you can put them to use to perform some web searches. Are you ready?
In Xcode, open DuckDuckGo.swift. At the top of the file, add the import below:
import Alamofire
Next, replace the existing definition of performSearch(for:completion:) with this:
func performSearch(for term: String, completion: @escaping (Definition?) -> Void) { // 1 let parameters: Parameters = ["q": term, "format": "json", "pretty": 1, "no_html": 1, "skip_disambig": 1] // 2 Alamofire.request("http://ift.tt/2eVRfp6;, method: .get, parameters: parameters).responseData { response in // 3 if response.result.isFailure { completion(nil) return } // 4 guard let jsonData = response.result.value else { completion(nil) return } // 5 let decoder = JSONDecoder() let definition = try? decoder.decode(Definition.self, from: jsonData) // 6 if let definition = definition, definition.resultType == .article { completion(definition) } else { completion(nil) } } }
There’s quite a bit here, so let’s break it down:
First, you build up the list of parameters to send to DuckDuckGo. The most important two here are q: the search term itself, and format: which tells the web service to respond with JSON.
Then you perform the request using Alamofire. This call makes a GET request to http://ift.tt/2rlcN3h, using the parameter dictionary created above.
Once the response comes back, check if the request failed. If so, exit early.
Optionally bind the JSON response object to ensure it has a value.
Next, use JSONDecoder to deserialize the Definition, which conforms to Codable.
The DuckDuckGo API can return a range of different result types, but the one covered here is Article, which provides a simple definition of the search term. You filter fpr article then pass the retrieved definition to the completion handler.
Note: If you’re wondering why the skip_disambig parameter exists, it’s to tell DuckDuckGo not to return ‘disambiguation’ results.
Disambiguation results are like those pages you see on Wikipedia: did you mean Chris Evans the movie actor, Chris Evans the British TV personality, or Chris Evans the train robber?
skip_disambig means the API will just pick the most likely result and return it.
Build and run! Once the app starts, enter “Duck” in the search bar. If everything’s working correctly, you should see a definition on the next screen.
There’s one thing missing, however: a picture! It’s one thing being able to read what a duck is, but who reads anymore? Pictures are worth — okay, I’ll spare you the cliché — you know what I mean.
Anyways, who doesn’t like looking at pictures of ducks? Kittens are so last season, right?
Open DefinitionViewController.swift, and add import AlamofireImage just below the existing UIKit import at the top:
import AlamofireImage
Then, at the following code just below viewDidLoad() method:
override func viewDidAppear(_ animated: Bool) { super.viewDidAppear(animated) if let imageURL = definition.imageURL { imageView.af_setImage(withURL: imageURL, completion: { _ in self.activityIndicatorView.stopAnimating() }) } }
af_setImage is an extension on UIImageView provided by AlamofireImage. You call it to retrieve the image found in the definition imageURL. Once retrieved, the activity indicator’s animation is stopped.
Build and run, and perform your search again.
Quack quack!
Where To Go From Here?
You can download the complete project here. (Don’t forget to run carthage update --platform iOS to build the dependencies.)
Congratulations, you’ve learnt about the philosophy behind dependency management and behind Carthage itself, gained some experience using Carthage to add some dependencies to a project, and used those dependencies to make a useful app!
You also know how to update your dependencies for future releases.
If you want to learn more about Carthage, your first stop should be the Carthage README and the documentation on Build Artifacts.
Justin Spahr-Summers, one of the project’s founders, gave a smashing talk at Realm.io about Carthage, entitled “Ruthlessly Simple Dependency Management.”
Finally, if you’d like to learn more about Swift Package Manager be sure to read the official documentation. About CocoaPods, you can checkout our tutorial on How To Use CocoaPods With Swift. It also contains a great section on Semantic Versioning, which you saw in use in Cartfiles.
I hope you got a lot out of this Carthage tutorial. If you have any questions or comments, please join in the forum discussion below!
The post Carthage Tutorial: Getting Started appeared first on Ray Wenderlich.
Carthage Tutorial: Getting Started published first on http://ift.tt/2fA8nUr
0 notes
knotfodder · 7 months
Text
Tumblr media
"Never seen thee or touched thee, but known thee with all of my heart"
name: Lorenzo Dulcinea Combs nicknames: Lore, Dulce, Enzo dob. age: May 13 (30) gender: Male pronouns: (he/him/his) secondary gender: Omega occupation: florist species: faerie fc: Rafael Silva
Tumblr media
+energetic, charming, optimistic.+ -ditsy, scatter-brained, forgetful.-
1 note · View note
knotfodder · 7 months
Text
-
0 notes