A simple remote local logger (with a nicer gui)

Oct 17 2017

I have spent way to much time finding logs and then do-someting, refresh-log-viewer, do-something, refresh-log-viewer, … to repeat in absurdum.

The refresh part is solved with tail or Notepad++’s tail or other options
but it doesn’t work over the wire (or at least I didn’t get it to work).

So I suggest having a simple tail implemented as a simple stand alone web server. Start this “tail” on the machine you have log files. Then you can surf to the web server and with some nifty CSS/javascript have a tail traversing your intranet on a port of choice like so: https://MyServerInTheCellar:666

To avoid polling use SignlR or similar.

If you want it to stay active for days a more stable solution should be crafted.

Highlight latest rows

A nice feature would be to highlight the latest rows. There must be a time limit of sorts to figure out what the “latest” means as the computer (yet) cannot read your mind and know what rows you have looked at and considered.

For simplicity say there is a time limit of 0,5 second where everything inside that interval is considered the same burst of log rows. Color this burst differently to distinguish it from earlier ,and later later, rows.
This should make it much easier to read.

Is it already made?

It seems WebTail does approximately what I am writing about but it polls. It is pleasantly GPL and is written in Java.

I have created bits and pieces of this solution but not anything passed alpha.

I have also noted that Notepad touches the file twice; so if you plan to create this solution don’t use Notepad to figure out how to register and read file changes in Windows.

I found a spike of mine called Farmer Charlie Sprouts at Github. Here is another, even older, project Farmer Logan and his cow called Loui at Github, this time solving the problem of showing the latest updated log rows in an easy-to-read manner.

No responses yet

A set of cameras for levelling stuff when building

Aug 01 2017

Say your are building a simple fence. What is not so simple is that every pillar must be in level and vertical.
The normal way of doing this is to have a spirit level, laser line level, water level or even theodolite.

Why not have a (self levelling) camera or two. or three?

Since the camera knows its orientation and its lenses and in turn optical aberations it can say what is level and in line and not.
Point out the pillar you want vertical and let the software in the camera do some image recognition and tell you when it is. Add another camera looking at the same pillar, but from another angle and the pillar’s angle is shown to you in all directions.

Now each camera has 3, or more, of the pillars in view and can tell you both if the pillars are vertical and if they are aligned and if they are level.

Use the same camera and software to help you with attaching the pickets equidistance.

If you give the camera some clues about distance, for instance by attaching or showing a ruler at some clever positions, it can return measures directly without you having to take out the laser range finder, carpenter’s/folding ruler or tape measure.

If you give the camera(s) more information with calibration points, like balls mounted on a stick stuck steadily into the ground, you can move the cameras around and the system will still know where it is.

Focus and focus point is a problem as optical aberrations might change when refocusing.

No responses yet

A cooperative buyers’ app

Aug 01 2017

Say you and your spouse is shopping food together. You are both running in the same store and looking for the same goods. You have to check in with each other often to sync what each have taken and what you should continue with.

Instead there could be an app, or simple web site, that does the syncing.
Let’s say you have a shopping list stored in your phone. You give it, or you are given, a unique id. Give this code to your spouse.
As soon as you check any item on the list a signal is sent to the other phone, directly or over internet, to check the item on other phones using the same code.
That way you can go shopping together without having to go back and forth to the shopping cart to discuss.

Extra bells and whistles could be the ability to send small messages like “double the milk” or “do we have eggs at home?”

No responses yet

An open source replacement to xsd.exe

Jun 13 2017

Microsoft’s XSD.exe is often used for creating DTO classes from an XSD.

The program has its opinions and it is a bit dated.

What is needed is a new implementation that not only returns a more modern output but that also is adaptable for personal quirks.

There are more people that needs this.
https://stackoverflow.com/questions/386155/comparison-of-xsd-code-generators

There are alternatives already.
One (that I have not tried) is Xsd2code (that lives on Codeplex that is soon shutdown, so if you need it, grab it (and move to e.g. github). Remember though that it is dual license.)

There is also the alternative to manipulate the output of xsd.exe.
I found a, by me untried, example at Codeplex called XsdTidy.

No responses yet

A grill with adjustable height on the grill

May 27 2017

During the 70s we hade (coal) grills where one could adjust the height of the grill by moving it up and down with ease. That simple functionality seems to have disappeared. Look at the common Weber grills, Green egg, Landmann, you name it. They all have fixed height on the grill.

The solution, it is said, is to put the coal to one side. Why? I ask. Why not just raise or lower the grill and use the whole of the grill.

Time to, not invent, not reinvent, but just simply pick up a solution that worked 40 years ago and still today.

Addendum:

Without being a historican I guess that changing the distance between the fire and the meat has been done since fire was put in use for cooking.

No responses yet

A simple working deep copy in dotnet

May 23 2017

Dotnet lacks a good canonical deep copy method or lib.

There are some solutions like
What you you find on Stack overflow
and simple libraries that I have not tested.

There is Automapper which does deep copying and a boatload more. My beef with Automapper is its singleton behaviour. Either I have misunderstood how it works or there is no way to use it throughout a 3 layer solution where there is no assembly that knows all other assemblies.

No responses yet

Save everything!

May 19 2017

Why not have a process listening to your development folder and stash every change (except bin, obj, cache etc.)?

This way one can roll back and forth throughout a whole day or week or even month to find the spot where something worked or something was changed.

Name the stashes in such a way that a nice little GUI can list the stashes and some some more information, like which files were touched.

Praise where praise is due: Rider from Jetbrains has it.
Since they provide the IDE they can do some clever thinking about how to group changes. With a file listener it is hard to tell if 2 file change close in time is one or two changes. Nevertheless; it doesn’t have to be perfect. Stashing every change takes you a long way to finding that change that ruined your day.

No responses yet

A code editor that doesn’t use the document metaphor

May 10 2017

I dare say all main code editors today use the document metaphor; text in a document read from top to bottom.
I dare say time has come to drop this metaphor to a more object oriented or data flow oriented one.


When writing a class in an object oriented language the resulting document usually, contains the properties in the top and the methods below.
This means that when looking at the code reading a property name means it is easy to read other properties as they are close by in the document. But is this really what you want? – isn’t the methods using this property what you want to look at?

Now say you are debugging the Save method. There is a great chance you have method Restore (alphabet wise R is next to S) on the monitor; despite you being totally uninterested in them.

What you instead want to have before your eyes and withing a keystroke are the properties User and IsAdministrator and the method Validate; because they are part of the data flow method Save uses.

You are probably also interested in who calls Save and who is called by Save.

My proposal is this:

When you are working with a method, in your vicinity you want what Save reads and manipulates. Any property is shown in a window above the method you are working with. To the right you have a list of methods, and possibly some code, to all methods that are called from the method you are working with and to the left you can see all ways to call your method.
Equally easy to see and navigate to are the parents and descendants of your class.

3 responses so far

App for finding sports mates for friendly match in the vicinity

Feb 05 2017

What if you have an area suitable for football in the vicinity but not enough friends to play?

Why not have an app where you describe the lawn and level of seriousness to let others join?

Or say you have a team of 6 but want another 6 to play with?

Or you want to play some sports but don’t know where people are playing?

There should be an app for that.

Enter location, time andlevel of seriousness in an app. Other interested in the same area; who feel like playing, get a popup and you all get together and play.

The idea could be extended to the drummer calling in sick at last minute, garage sales, apple picking, sailing crew, swimming company or shopping company.

Update 20200816

I saw one at the local lawn. Something football-ish. Nice!

No responses yet

A shopping app that adapts to your behaviour

Nov 05 2016

Most shopping apps are a list of text. They typically contain some aids for easily writing gherkin, and cantaloupe and how many but they are still a list from top to bottom.

Most grocery stores have vegetables in a part of the store so when you pick the tomatoes you probably want the corn and the apples at the same time; but not the milk, chocolate or spices.

So I suggest the list reorders itself when you start picking to show what’s nearby.

One can also use the localisation features of the phone to find out which store you are in and adapt even more as it then can know whether bread is in the start of the store or later.

No responses yet

« Newer - Older »