Why not try a little test? Look at the labels on your clothes. Check the one on your shirt or your trousers. Now go into the wardrobe and do the same with the clothes hanging up in there. What do their labels say? Bangladesh maybe. China probably. There’s even a chance that bit of knitwear or tartan scarf you have was made in the Far East because that’s how much of the clothing industry works these days. And it’s a reality that’s having a dramatic effect on what used to be the world’s capital of knitwear: Hawick in the Borders.

I try the test on some of the people I meet when I visit the town. Billy Hush is a former shop steward who’s worked in knitwear for nigh on 40 of his 55 years and he says he’s just like everyone else when it comes to buying clothes. “I’ve looked at all my labels, my shirts, everything,” he says, “and they say Bangladesh, Taiwan; it’s unbelievable. So I was part of the problem in a way.”

The effects of the problem – cheap imports, a struggling industry, lack of investment – have been obvious for years, but 2016 has been particularly bad. First, Hawick Knitwear, which has been manufacturing in the town since 1874, entered administration with the loss of 200 jobs (Hush was one of the workers who was laid off). Then Peter Scott, also one of the oldest knitwear companies in the town, announced it was ending its production operations, with the loss of another 80 jobs. Everyone I speak to talks about what it felt like. In January, Hawick was hit by severe flooding which swept away buildings and bridges. That’s what it felt like: a disaster.

But, un-knot the problem, pull at it a bit and there are definite signs of hope and progress. Hawick is not like one of the former mining towns in Ayrshire that never recovered from the loss of their industries – there is still a knitwear industry here, it’s still taking people on, and there’s a small but healthy training school that’s attracting incomers. But the industry is a fraction of what it once was, wages are low and seasonal working makes it hard for people to make a decent living. Which raises some critical questions: will it get better? Why are some companies doing well and others like Peter Scott in trouble? And what is the best way forward?

First: the basics, which are the same as they ever were really. I visit Johnstons of Elgin’s factory by the river and the layout is pretty much as it’s always been: one big room filled with the massive frameworks that produce the arms of jumpers and the fronts and backs and the constant clack-clack sound of the machinery. Along the side of the room is a row of desks where the finishers do the more delicate work and along another are the sock machines. We stand for a few minutes and watch the machines’ delicate, complicated work. In goes the wool at one end and a few seconds later out comes a sock from the other.

It’s a quality product they’re making here, often for designer clients such as Chanel, and there’s a great demand for it too, particularly in the Far East, where the middle classes love to drink Scottish whisky and wear Scottish clothes. But for some companies, the demand has not translated into a sustainable success. Earlier this year, Hawick Knitwear went into administration before being bought by a new company called Lyber 2016, which is owned by the Chinese cashmere supplier Artwell. Some of the Hawick Knitwear staff were kept on; most had to find jobs elsewhere.

And then there’s Peter Scott, which seems to have inflicted a particularly deep wound on the confidence of the town. The company has been here, producing knitwear, for more than 130 years, but this summer the workers were told production would end. It means all but a skeleton staff has been kept on and it’s a sad end to several years of problems. The firm went bust in 2011 before being bought by the South Korean company Gloverall but now they have effectively pulled out. The staff desperately tried to save it, but in the end they were told there was no solution and the production would end.

Jean Kennaway, 55, was one of those who worked at Peter Scott (and has since found a new job at Johnstons) and she says the company’s demise was expected. “It didn’t come as a surprise because you hear what’s going on,” she says. “I couldn’t see how it was going to survive because there has been such a downturn in knitwear, some people have had to diversify into other industries.”

Kennaway has been in knitwear since she left school at 16 and was at Peter Scott’s for 34 years. There are many others like her: men and women from families of textile workers. I speak to one retired worker, 79-year-old Andy Amos, who worked at Pringle and reels off his family history. “My dad was in Pringles, my mother was in Pringles, my brother was in Pringles and I was in Pringles.” He takes me to the old Pringle plant on the other side of the river from Johnstons. It closed in 2008 and is now rusting away. We stand at the gates and look through. There used to be long queues here every morning, he says, queues of people waiting to clock in.

Kennaway remembers the busy days at Peter Scott too and says the decline of the company was unsettling. “It was very upsetting to see Peter Scott go down,” she says. “There were several generations who worked in that factory. There’s a man who lives in my street who’s 80 now and in a photograph at Peter Scott there were three generations of his family.” But Kennaway is bullish: you have to move on, she says, she’s been in the industry since she was 16 and still is, although she could never afford to live in a city with her wages. Like many of her colleagues, she’s surviving but not on much.

There are similar stories at Hawick Knitwear. Billy Hush was there for 39 years and for the last 10 was shop steward but he was laid off earlier this year and was out of work for 12 weeks. He has since picked up seasonal work, but it’s not like it used to be in the early days when there were good pensions and nice bonuses. There’s work out there, and most of those made redundant by Peter Scott and Hawick Knitwear have found other jobs, but the question is: what kind of jobs?

“What I’ve come up against now is that I’m only being taken on for the summer,” says Hush. “I’m ten a penny now, there are hundreds out there – people can afford to take you on for the busy time and then lay you off.” The pay is also not great. “You will pick up something. It will be minimum wage, you will go from £10 or £12 an hour to £7 an hour, and you’ll struggle on until it gets better. It’s hard to make a living.”

Ann Douglas has a similar story. She’s 48 and was at Hawick Knitwear for almost as long as Hush – in her case, 31 years – and was in tears the day she was told it was all over. “I was 16 when I started there, just after my 16th birthday in 1984,” she says, “and I didn’t see it coming. I never had any inclination at all. I finished straight away when it went under and it was very upsetting, especially when you had no idea.” She went round all the different mills and filled out application forms and eventually found work, but the pay’s only “OK” she says.

So why has this happened, why have Hawick Knitwear and Peter Scott and others like it failed or declined? Peter Scott would not speak to The Herald, but almost everyone I speak to in the town agrees on the essential problems: cheap imports and, at companies such as Peter Scott and Hawick Knitwear, an emphasis on low costs rather than quality and a failure to invest in new technology. Partly, this was an attempt to keep costs down and compete with the cheap knitwear on sale in the high street, but the workers in Hawick think that process was doomed from the start – Peter Scott was trying to produce big bulk orders – quantity rather than quality and it couldn’t keep up.

The other problem, according to those who have worked in the industry, is inexperienced managers trying to cut costs. Andy Amos says he saw it at Pringle. “They brought in directors who didn’t know what they were doing,” he says. “There was one chap who came in on quality control, which in knitwear is the number one factor, and he came from a cement factory in Ireland. They also tried to reduce the quality.” The answer, he says, is to go the other way: to produce a good-quality product that people want to buy.

They are doing that at Johnstons of Elgin and have made a success of it – so much so they have started a training school which is taking on apprentices. This is on a much smaller scale than the old days, but they are taking people on. People like 38-year-old Karen Lammi who is returning to work after having children and 20-year-old Jenny Turnbull, who is doing the traditional thing and following her father into the industry. There are even incomers like 25-year-old Kirstin Stewart, who has a textile degree and has come from Dundee to work here.

There are also positive signs at the Hawick Knitwear operation, although it is much smaller than it was – Hawick Knitwear employed 180, the new company Lyber 2016 has a staff of only 40. I speak to the managing director, Arthur Rennie, who was made redundant at Hawick Knitwear along with everyone else, and he tells me about his shock when Hawick Knitwear went under.

“The company’s financial performance wasn’t great but we believed there was an investor coming on board who didn’t materialise. We felt we didn’t have time to find another investor,” he says. So what went wrong at Hawick Knitwear? “I think the consensus after the dust has settled is that the production capacity was too large and it was a continual battle to try to find enough orders to fill it. A lot of the bulk contract work that was sought to keep the factory running was very low margin, but the Hawick Knitwear branded products had a very healthy margin. Our strategy is in between – it is at the much higher-value end. A lot of the Hawick Knitwear business was in the lower-value lambswool.”

Rennie also says there is potential for growth. “Business doesn’t get any easier but we’re not dead and buried yet, and there is a hardcore of retailers who rely on Scottish-made knitwear.” He thinks Japan has particularly strong potential and says the market in China is mind-boggling – the problem is making in-roads into it. The company’s current strategy is to be a quality cashmere knitwear supplier and longer term develop its own brand identity.

But it will need investment. Rennie says it could come at Lyber, but it will be cautious and market led. Others in the industry believe the Scottish Government should be investing more. Earlier this month it was announced that £10 million would go towards local economic development projects and the government tells me that some of that will go to Hawick, although they won’t say how much before the official announcement later in the year.

Is it enough? Two of the local councillors I speak to, Watson McAteer and Stuart Marshall, say the government should be setting up an enterprise zone with incentives for start-ups; McAteer is also disappointed that he hasn’t seen more of Paul Wheelhouse, who is the minister for business, innovation and energy, and a local MSP.

But Wheelhouse says action is being taken through the Hawick Action Plan, which involves the government and a number of organisations including Scottish Enterprise.

“We have been working with Scottish Borders Council to look at actions in the Hawick Action Plan to help revitalise the town," he says. "I am pleased to say we intend that some of the £10m fund be used to deliver aspects of the plan to encourage start-ups and help retain growing businesses in the town and improving the resilience of the local economy following recent job losses.

"Ensuring those resources can have most impact is now vital and we are working to agree the exact scope of the projects that can be funded, and more details will be announced in due course.”

As for the workers I speak to, they also expect more from the government, although they also say much of the responsibility lies with companies. The ones that are thriving, it seems, are those that are family owned or have made an investment such as Johnstons or have people at the top who are connected to Hawick and have wide experience in knitwear. And rather than cutting corners, the successful companies are going the other way and producing good-quality garments.

Peter Scott is all but gone after 160 years, the Pringle factory is slowing rotting by the side of the river and the industry is a fraction of what it once was. But there's the training school and some investment and a market out there for the taking – signs of hope and the beginnings of a plan.