The Lounge is rated Safe For Work. If you're about to post something inappropriate for a shared office environment, then don't post it. No ads, no abuse, and no programming questions. Trolling, (political, climate, religious or whatever) will result in your account being removed.
1. The lounge is for the CodeProject community to discuss things of interest to the community, and as a place for the whole community to participate. It is, first and foremost, a respectful meeting and discussion area for those wishing to discuss the life of a Software developer.
The #1 rule is: Be respectful of others, of the site, and of the community as a whole.
2. Technical discussions are welcome, but if you need specific programming question answered please use Quick Answers[^], or to discussion your programming problem in depth use the programming forums[^]. We encourage technical discussion, but this is a general discussion forum, not a programming Q&A forum. Posts will be moved or deleted if they fit better elsewhere.
4. No politics (including enviro-politics[^]), no sex, no religion. This is a community for software development. There are plenty of other sites that are far more appropriate for these discussions.
5. Nothing Not Safe For Work, nothing you would not want your wife/husband, your girlfriend/boyfriend, your mother or your kid sister seeing on your screen.
6. Any personal attacks, any spam, any advertising, any trolling, or any abuse of the rules will result in your account being removed.
7. Not everyone's first language is English. Be understanding.
Please respect the community and respect each other. We are of many cultures so remember that. Don't assume others understand you are joking, don't belittle anyone for taking offense or being thin skinned.
We are a community for software developers. Leave the egos at the door.
I'm afraid it is.
LEGO ain't cheap, especially one of the biggest consumer sets ever
Maybe Star Wars LEGO is slightly more expensive too because of licensing issues.
It'll look great once it's finished though
I am soon doing a major re-factor / start over and take what still is usefull of a product where several things are working together and I would like to re-structure it a bit. I already see advantages and disadvantages on both approaches. Just want to "hear" about your tastes / opinions.
The current project has a section of "static" files for configuration staff.
A huge C++ part with over 20 tiny apps separated in threads, a cpp server to manage them, some cpp third party libs / add-ons...
The .Net Framework with some libraries, a couple of background services, some different WPFs, a bunch of tiny satellite apps...
In the next major version we want to move to the next Standard LTS (IIRC is .Net 6 somewhen in the end of 2021), so right now what is getting redone from the scratch and some background performance improvements that I want to test is getting targeted in .Net Core 3.1
If something has a solution... Why do we have to worry about?. If it has no solution... For what reason do we have to worry about?
Help me to understand what I'm saying, and I'll explain it better to you
Rating helpful answers is nice, but saying thanks can be even nicer.
I would prefer the second way, this will save you a lot of time in a complex solution e.g. when you want to search the files in a directory. Example: search for some error message from Notepad++ with "search in files".
I prefer the former because I often find that I have build scripts that invoke language specific tools, so I might have input files for the CPP project that are not source files, but rather, input files for tools that generate source files. Same with C#
There are other cases too where I might have non-source inputs that are nevertheless language specific.
Putting everything under the CPP branch, including the non-source input files - everything that is needed to build the CPP project makes it easier to use and copy the projects as complete and hopefully self contained sub-projects of code. I mean sure, it's not the entire overarching project, but where I can I prefer each sub-project to build on its own as much as feasible.
The same goes for the CS projects as it does for the CPP, i just used CPP as the example above.
The files making up one language implementation are closely related to each other. Keep closely related files close together. Files in different languages, being processed in different ways, maybe even demanding a different modularization (at least at low level) gains very little from being close together.
But I guess that your case is a single implementation, with different parts written in different languages (e.g. that the cpp code provides p/invoke interfaces, or you are running a WPF GUI in a frontend process, communicating with a backend working process written in C).
In that case, alternative B is obvious to me. Again: Keep closely related (e.g. coupled as caller and callee) files close together.
Why keep files close?
Another reply already mentioned directory-wide searches: You will want to search in a the code you are working on, with as few false hits as possible to stuff you are not working on. Caller and callee should be in the same (sub)directory.
Second: With parallel versions in different implmentation languages, you usually make a release for one language at a time. The tests are passed at different times. The system integration done at different times. So you would want to make the checkpoints etc. (e.g. creating an offline backup of all source code) at different times. Most such tasks are much simpler if the files involved are gathered in a its own subdirectory.
If you have a single implementation (with parts in different languages), but split into major subsystems, you may create new releases of each subsystem at different times, or at least you complete full testing at different times. Again, you would like a checkpoint to relate to a whole subdirectory, not some files here, some there.
I am curious about your splitting off "Test". For low level, module testing I find it natural to put it close to the code to be tested - logic module tests in the Logic directory, GUI tests in the GUI directory. Maybe even lower: If you e.g. put module test C# code into a partial class, having to climb several levels up towards the root and down several levels into the Test directory to find the test part of the class doesn't feel right. They partial classes are closely related, and should be locaded close together. It is like if you made a directory at the level of Cs, Cpp, Test, where you gather all the header / interface files in all the languages used in one place - that is not what you would do!
Integration and system tests are different matters: They should be separate from the modules they integrate, in its own directory the way you have indicated.
As I am playing Assassin Creed for the first time, I am learning of those who came before, our creators, the mighty Isus.
Now, I am in awe and want to learn their wisdom.
Brother Assassins, who have followed this path before, let me know if I am on the Way of enlightenment!?
Here is a simple ethical questionnaire that will judge my progress on the way of the Isu, with my answer after each question.
5 innocents are tied on a trolley's track A. And 1 innocent is tied on a trolley's track B.
The trolley is on its way to crush people on track A very soon. However you have the power to make it go to track B, hence killing only one person.
1. do nothing?
2. change its path to be on track B?
A: 1, Let the trolley continue! Life is pain, and killing 5 people is better at reducing misery!
A heinous crime has been committed and 2 suspects have been arrested, but it's not entirely sure if either is guilty. You are the judge condemning them.
1. kill them both?
2. arrest them both for 10 years?
3. let them both go?
A: 1, kill them both, just to be safe. The guilty will surely be punished this way!
Your friend is hopelessly depressed. His one true love doesn't love him back He wants to kill himself.
1. help him commit suicide to end his misery?
2. convince him there is more to live for?
A: 1, In death he will rest in peace. Achieving the ultimate goal of life!
Did I get that right?! Am I becoming as wise as the mighty Isus?
My new cat, Pink, ran away last week.
Haven't seen her in 8 days now, but someone ate all her food a few nights back.
She's probably near and coming home every few nights to eat.
To make sure, I bought a camera with night vision that can detect and follow motion, notify me of any motion and record up to a few days.
I'm aiming it directly at the cat hatch so I know when she's in.
Not a fan though, this kind of stuff is often badly secured and I wouldn't be surprised if the manufacturer is now following my every move.
I hope I get Pink back soon and I can unplug and box this camera again.
My cat flap is very basic, it has but one mode.
It also has to be open permanently (using tape, because I cannot remove the flap without disassembling the whole thing) because she doesn't know how a cat flap works yet.
In hindsight, it would've been worth it to pay a little extra for a good cat flap
She "escaped" when the door was open.
I let her, because she was meowing at the door every night.
Two weeks ago she went to explore, but something scared her and she came running back, so I thought it would be alright.
Last week she also started off exploring the garden and did not go too far, until she did