MBBSV10 Cleanup Additions

Chat, tips, tricks and help for Veteran Sysops
Post Reply
User avatar
Frank Dux
Posts: 24
Joined: Tue Dec 22, 2020 12:22 pm

MBBSV10 Cleanup Additions

Post by Frank Dux »

Running BBSV10? You OCD about keeping it pristine?

There's a couple of things going on that you might not be aware of:
- Your file case is a dog's breakfast right now; it's all over the place and inconsistent. Change it and it goes back.
- If you have Annex's Registry Gold, you might note that BBSV10 keeps recreating partial folder structure for it's CS mode.
- Lastly, there's a FL(a)G file that gets generated when you make certain changes such as adding new modules, changing menu, etc - WGSCMAPS.FLG. The whole WGSCMAPS.EXE mapping conversation is out of scope for this discussion, however, the purpose of this file relates to C/S modules; on BBSV10, this is not required.

Usual disclaimers in play here; please test on your staging/backup instances first. If you do not have your own method already, I recommend using KDiff3's directory compare feature on a before and after copy of your BBSV10 folders (Copy the folder, run the script, compare with original copy, click toolbar button to hide files that are identical, this will highlight everything changed)

Caveat #1: Tested on a new install of BBSV10
Cavest #2: All scripts are in 1 file: WGSCLEAN.PS1
Caveat #3: The following line needs to be added to your WGSCLEAN.BAT:
Powershell.exe -executionpolicy remotesigned -File C:\BBSV10\WGSCLEAN.PS1
Caveat #4: I use variables in my scripts, but have removed them and placed the raw names for simplicity here

1. Case consistency:

I'm old school, I like all UPPER case for BBS files. Add the following lines to your WGSCLEAN.BAT file. It only touches files that meet the requirement. If you prefer all lower case, switch them around. Does not touch the license agreement on purpose. (That's a nice looking case)

# This line converts all existing 8.3 "lower" case files to "UPPER" case.
Get-ChildItem -Path "C:\BBSV10" -Recurse | Where-Object { $_.Name -cne $_.Name.ToUpper() -and $_.Name -match '^[^.]{1,6}\.[^.]{1,3}$' } | ForEach-Object { $tn="$($_.Name)-temp"; $tfn="$($_.FullName)-temp"; $nn=$_.Name.ToUpper(); Rename-Item -Path $_.FullName -NewName $tn; Rename-Item -Path $tfn -NewName $nn -Force; Write-Host "New Name: $($nn)";}

2. Annex's Registry Gold Client/Server directory cleanup. This will remove the ANXREG folder structure that keeps getting created when changes are made from your clean BBS10 folder structure since C/S mode is not a thing in this version.

EDIT: Same goes for HSV's News Room (HSVNR)

# This line removes the ANXREG folder structure that gets generated if WGSCMAPS.FLG was created and compression check was run.
Remove-Item -Path "C:\BBSV10\ANXREG" -Recurse -Force
Remove-Item -Path "C:\BBSV10\HVSNR" -Recurse -Force

3. The ANXREG structure keeps getting created because WGSCMAPS.FLG was generated. The contents of the file are 1 line; for complete transparency, here it is: "Flag file: check apps for compression". This is not required on BBSV10. Prevention is better than a cure.

# This line removes the WGSCMAPS.FLG file if it was generated during the course of your last session or prior cleanup activities.
Remove-Item -Path "C:\BBSV10\WGSCMAPS.FLG"

That's it for now.

Unfortunately, I converted my machines to windows 10 and BBSV10 doesn't run; crashing on close/cleanup (Windows 7 was fine). Least I can do is pass on what I've learnt during my testing.

Reach out if you have any questions or requests.

Happy tinkering.

Post Reply