Stories
Slash Boxes
Comments

SoylentNews is people

Log In

Log In

Create Account  |  Retrieve Password


Please to Write a Shell Script for Me and for Yourselves

Posted by MichaelDavidCrawford on Wednesday May 16 2018, @08:29AM (#3238)
20 Comments
Code

Such a script would ease the burden of implementing a few site-wide changes to The Global Computer Index.

As it stands 319 HTML files need to be revised in one or more of four separate ways.

Simply to contemplate such laborious and tedious work gets down so I focus on the smaller countries first, as well as the countries of whose cities I list only a very few.

I use find to produce a list of all the files that require revision. What I'd like is a script that sorts that into countries - or into US states - that have the fewest cities that require revision.

That won't save me any effort but it will make me far more productive. It's much easier for me to initiate a task if it at least appears to be a small task.

Here's some sample data:

$ find . -name index.html -exec grep -l 'Computer Job' {} \; | grep -v united | tail
./pakistan/rawalpindi/index.html
./philippines/manila/index.html
./poland/gdansk/index.html
./poland/warsaw/index.html
./russia/moscow/index.html
./russia/novosibirsk/novosibirsk/index.html
./russia/tomsk/index.html
./russia/tomsk-oblast/index.html
./serbia/belgrade/index.html
./singapore/index.html

In this list I would start with Singapore then go on to Serbia and the Philippines.

If I only needed to change "Computer Job" to "Computer Industry Job" I would use sed. But sed alone won't do it because I often have to break long lines into smaller chunks so as to make iFone Fanbois happy.

I'm also migrating my entire site to HTML 5 - but many of my as-yet-unrevised pages are _already_ HTML 5 but some get warnings when I validate them.

Some have spelling errors. Some have errors that doubtlessly would lead foreign patriots to undertake a vendetta against me, my male children and all their male children.

So really I do need to at least inspect all 319 candidate files.

I thank you, and your future managers thank you.

Youngest Flexer of the Century

Posted by takyon on Tuesday May 15 2018, @07:51PM (#3237)
2 Comments

Murder of Two Cyclists Covered Up in Mexico

Posted by takyon on Sunday May 13 2018, @01:04AM (#3231)
6 Comments
News

Mexico says round-the-world cyclists were murdered

Mexican investigators say two European cyclists did not die in an accident as first claimed - they were murdered. The bodies of Holger Hagenbusch, from Germany, and Krzysztof Chmielewski, from Poland, were found at the bottom of a cliff in Chiapas state.

Local authorities had said the pair appeared to have fallen after losing control. However, relatives and fellow cyclists suspected it was more sinister, and had called for a deeper investigation.

The newly appointed special prosecutor, Luis Alberto Sánchez, said, on Friday, that they were killed in what appears to have been a robbery. "Our investigations up to now indicate this was an intentional homicide," he said.

[...] After travelling to Mexico to identify his brother's body, [Reiner] also found out information about the Polish biker. "The Polish cyclist was decapitated and had a foot missing," he wrote on Facebook.

[...] Chmielewski sustained a head injury that may be a gunshot wound, said Mr Sánchez. His body was found next to a bike - but it was not his own. It belonged to his German companion, which aroused suspicions.

Soggy Jobs is Getting Some Traction

Posted by MichaelDavidCrawford on Friday May 11 2018, @01:06AM (#3228)
10 Comments
Code

So far in May 2018 I'm averaging 2400 hits per day, 350 of which are for http://soggy.jobs/.

I'm going to set up a Tor Hidden Service for Soggy Jobs just so the Gestapo your boss figures your just hanging out on a pr0n throughout your workdays.

Those figures include both live humans and robots. I have some code at home that will remove most of the bots. I expect to sell the code but supporting IE log files just makes my head spin.

So I'm going to release it as Free Software, with the ReadMe.txt file advising the user to change their log file format to Apache's "LogFormat combined". That's a popular format; it would be straightforward to configure other servers to use it, and whadda ya expect? It will be Free As In Freedom!

Real Soon Now I'm going to write some Python code that informs me when a Soggy Jobs listing needs revision.

"Real Soon Now".

To my great delight, someone from a company that I list requested that I hyphenate their domain name. I just did.

I speculated that she didn't know about HTTP Permanent Redirects so I advised her to install one in their old domain's Apache config file - or perhaps an .htaccess file in their website's top level directory:

      Redirect permanent / http://ex-ample.com

The folks at WebmasterWord were leery of losing their PageRank this way so "Google Guy" redirected his entire domain, let it sit there for a while then verified that his SEO was unaffected.

I don't know how to configure redirects for the other HTTP servers.

LDS Church Splits With "Boy" Scouts

Posted by takyon on Wednesday May 09 2018, @05:48PM (#3223)
7 Comments

Is There a German in the House?

Posted by MichaelDavidCrawford on Wednesday May 09 2018, @06:33AM (#3222)
3 Comments
Career & Education

Presently I list only a few companies in the Germany section of The Global Computer Industry Index.

Yet my web server log files give me the insight that most of my visitors are from Germany. Clearly I'm not serving their needs yet.

Can you suggest some small- to medium-sized Software or Hardware companies for me to list?

It's easy for me to find publicly-traded companies as well as multinationals but even so it's OK if you want to point some others out to me.

At your option, mail your suggestions top incoming@soggy.jobs or alternatively post them in a comment herein.

I Am Eternally In Your Debt.

I Think There's Still Something Wrong With My Brain

Posted by MichaelDavidCrawford on Tuesday May 08 2018, @11:40PM (#3221)
6 Comments
Code

But I don't feel the need to go to the Emergency Room.

I'm going to ask my Primary Care Physician to refer me to a Neurologist.

I'm making the same kinds of mistakes that brain-damaged people do.

I was brutally beaten by two police officers in 2012. I was unconscious for three days.

When I woke up, while I could correctly visualize the spelling of my own name when I thought about it, I was incapable of spelling it right when I tried to write it on paper with a pencil.

The Great Soylent News Debug Meister's Challenge

Posted by MichaelDavidCrawford on Tuesday May 08 2018, @10:46PM (#3218)
0 Comments
Code

#!/bin/sh

id_addr=10.74.105.207

sudo chown -R root:wheel FL2000.kext/

tar cvfz FL2000.tgz ./FL2000.kext/

scp FL2000.tgz labuser@$ip_addr:Desktop/

sudo rm -r FL2000.kext FL2000.tgz

White Women's Weaponized Tears

Posted by takyon on Tuesday May 08 2018, @05:37AM (#3216)
15 Comments

I Think I Just Blew Subversion's Brains Out

Posted by MichaelDavidCrawford on Saturday May 05 2018, @01:44AM (#3211)
5 Comments
Code

It seems to be a problem with our server. Our sysadmin has the day off; I asked the Engineering VP if I should ask him to fix it today.

This just in: "Yes," replied the VP. Sucks to be a SysAdmin.

I tried to do an "svn resolve" when I suddenly found the macOS Finder's window that was open to my project hierarchy started boogieing.

By the time it was done with it's dance, most of what I had in trunk had been deleted.

I already sent the SysAdmin a mail to tell him that full checkouts fail after fetching a couple hundred files: "connection reset by peer".

I used to really _like_ Subversion. It's always a tragedy when a loving relationship is on the rocks.