30 Commits

Author SHA1 Message Date
Felix Rieseberg
a28aef8cf0 build: Oh, and don't install tree 2019-05-17 15:37:29 +09:00
Felix Rieseberg
d2b8d9dd35 build: Don't even tree 2019-05-17 15:31:48 +09:00
Felix Rieseberg
3802734ef0 build: Install tree on Linux 2019-05-17 15:31:13 +09:00
Felix Rieseberg
1f478676f1 build: Download images on Travis 2019-05-17 15:25:30 +09:00
Felix Rieseberg
d19bbeee8f build: Make standalone Windows builds 2019-05-17 15:25:21 +09:00
Felix Rieseberg
1e130b6140 build: Install x64 Node 2019-05-17 14:22:37 +09:00
Felix Rieseberg
e1c5992ff9 build: Add GitHub publisher 2019-05-17 13:56:02 +09:00
Felix Rieseberg
e879760678 build: Cut the flatpack 2019-05-17 13:43:39 +09:00
Felix Rieseberg
2a11633171 chore: Update version number to 2.1.0 2019-05-17 13:33:11 +09:00
Felix Rieseberg
b68d54ae62 build: Fix travis build 2019-05-17 13:32:28 +09:00
Felix Rieseberg
9600630340 build: Build on AppVeyor, too 2019-05-17 13:28:37 +09:00
Felix Rieseberg
bae1909793 build: What if we just don't asar? 2019-05-17 13:18:14 +09:00
Felix Rieseberg
ee9e138034 build: Enable verbose debugging 2019-05-17 13:01:56 +09:00
Felix Rieseberg
5558671688 build: Add a filename 2019-05-17 12:53:42 +09:00
Felix Rieseberg
9a46ed5080 build: Step by step, I guess 2019-05-17 12:43:54 +09:00
Felix Rieseberg
2c160d0f7f build: Add an AppVeyor file 2019-05-17 12:33:17 +09:00
Felix Rieseberg
aafab62707 chore: Update all dependencies 2019-05-17 12:30:03 +09:00
Felix Rieseberg
78126a57cb docs: Fix a typo 2019-02-22 11:41:46 +00:00
Felix Rieseberg
f5256ec7a2 docs: Add gitpod instructions 2019-02-22 11:40:56 +00:00
Felix Rieseberg
6c1687c9a5 Merge pull request #124 from jankeromnes/master
Add an online live demo
2019-02-22 11:39:07 +00:00
Jan Keromnes
2c041115d0 chore: Add online live demo 2019-02-13 15:31:23 +00:00
Felix Rieseberg
987dc57309 Merge pull request #117 from kant/patch-1
Formatting proposals
2019-02-12 00:05:42 -08:00
Darío Hereñú
614b18969d Formatting proposals 2019-02-08 13:58:24 -03:00
Felix Rieseberg
264ef7d069 Update README.md 2019-02-04 10:45:32 -08:00
Felix Rieseberg
e85cf4f1b2 docs: Add FrontPage credentials 2019-02-03 17:14:33 -08:00
Felix Rieseberg
e987da5460 docs: Update links 2019-02-03 17:13:39 -08:00
Felix Rieseberg
a542639bc3 docs: Update the readme with some answers 2019-02-03 16:49:19 -08:00
Felix Rieseberg
5d1928beb2 docs: Add instructions on how to mount the disk image 2019-02-03 16:45:58 -08:00
Felix Rieseberg
f1b657a53b docs: Remove link to CovalenceConf 2019-02-03 16:38:54 -08:00
Felix Rieseberg
6aa39e66ec 2.0.0 2019-02-03 15:40:31 -08:00
10 changed files with 1369 additions and 1133 deletions

45
.appveyor.yml Normal file
View File

@@ -0,0 +1,45 @@
environment:
matrix:
- nodejs_version: "10"
init:
- git config --global core.symlinks true
install:
# Setup the code signing certificate
- ps: >-
if (Test-Path Env:\WINDOWS_CERTIFICATE_P12) {
$workingDirectory = Convert-Path (Resolve-Path -path ".")
$filename = "$workingDirectory\cert.p12"
$bytes = [Convert]::FromBase64String($env:WINDOWS_CERTIFICATE_P12)
[IO.File]::WriteAllBytes($filename, $bytes)
}
- ps: Install-Product node $env:nodejs_version x64
- node --version
- npm ci
- ps: cd ./src/
- ps: mkdir images
- ps: cd images
- ps: Start-FileDownload 'https://1drv.ws/u/s!AkfaAw_EaahOkulh8rA41x2phgfYXQ' -FileName images.zip -Timeout 600000
- ps: 7z x images.zip -y -aoa
- ps: Remove-Item images.zip
- ps: Remove-Item __MACOSX -Recurse -ErrorAction Ignore
- ps: cd ../..
- ps: Tree ./src /F
cache:
- '%APPDATA%\npm-cache -> appveyor.yml'
test_script:
- node --version
- npm --version
- npm run lint
artifacts:
- path: 'out\make\squirrel.windows\**\*.exe'
build_script:
- if %APPVEYOR_REPO_TAG% EQU false npm run make
- if %APPVEYOR_REPO_TAG% EQU true npm run publish
- if %APPVEYOR_REPO_TAG% EQU true npm run publish -- --arch=ia32
- ps: Tree ./out/make /F

64
.travis.yml Normal file
View File

@@ -0,0 +1,64 @@
language: node_js
node_js: "12"
os:
- linux
- osx
dist: trusty
osx_image: xcode8.3
sudo: false
cache:
directories:
- node_modules
- $HOME/.cache/electron
addons:
apt:
packages:
- fakeroot
- rpm
branches:
only:
- master
- /^v\d+\.\d+\.\d+/
install:
- npm install
- mkdir -p ./src/images
- cd ./src/images
- wget -O images.zip https://1drv.ws/u/s!AkfaAw_EaahOkulh8rA41x2phgfYXQ
- unzip -o images.zip
- rm images.zip
- rm -r __MACOSX
- cd ../..
- ls src
- ls src/images
- |
if [[ "$TRAVIS_OS_NAME" == "osx" && "$TRAVIS_SECURE_ENV_VARS" == "true" ]]; then
export CERTIFICATE_P12=cert.p12;
echo $MACOS_CERT_P12 | base64 --decode > $CERTIFICATE_P12;
export KEYCHAIN=build.keychain;
# Create the keychain with a password
security create-keychain -p travis $KEYCHAIN;
# Make the custom keychain default, so xcodebuild will use it for signing
security default-keychain -s $KEYCHAIN;
# Unlock the keychain
security unlock-keychain -p travis $KEYCHAIN;
# Add certificates to keychain and allow codesign to access them
# Apple Worldwide Developer Relations Certification Authority
security import ./tools/certs/apple.cer -k ~/Library/Keychains/$KEYCHAIN -T /usr/bin/codesign
# Developer Authentication Certification Authority
security import ./tools/certs/dac.cer -k ~/Library/Keychains/$KEYCHAIN -T /usr/bin/codesign
# Developer ID Felix
security import $CERTIFICATE_P12 -k $KEYCHAIN -P $MACOS_CERT_PASSWORD -T /usr/bin/codesign 2>&1 >/dev/null;
rm $CERTIFICATE_P12;
security set-key-partition-list -S apple-tool:,apple: -s -k travis $KEYCHAIN
# Echo the identity
security find-identity -v -p codesigning
fi
script:
- npm run lint
- if test -z "$TRAVIS_TAG"; then npm run make; fi
after_success: if test -n "$TRAVIS_TAG"; then npm run publish; fi

17
HELP.md
View File

@@ -14,11 +14,22 @@ button to start your virtual machine again.
## I want to install additional apps or games
If you are running Windows 10, macOS, or Linux, you can probably "mount" the
If you are running macOS, or Linux, you can probably "mount" the
virtual hard drive used by `windows95` to add files. Hit the "Show Disk Image"
button in the lower right of the app, which will take you to the disk image.
On both Windows 10 and macOS, double-click the disk image to open it.
On macOS, double-click the disk image to open it.
On Windows 10, Windows will _think_ that it can open up the image, but will
actually fail to do so. Use a tool [like OSFMount][osfmount] to mount your
disk image.
On Linux, search the Internet for instructions on how to mount an `img` disk
image on your distribution.
image on your distribution. It's likely that you'll be able to run `mount`
with the image as input.
[osfmount]: https://www.osforensics.com/tools/mount-disk-images.html
## What's the FrontPage Username and Password?
Username: windows95
Password: password

View File

@@ -2,18 +2,16 @@
This is Windows 95, running in an [Electron](https://electronjs.org/) app. Yes, it's the full thing. I'm sorry.
Interested in Electron? Join as at [CovalenceConf](http://covalenceconf.com) in San Francisco!
## Downloads
| | Windows | macOS | Linux |
|---------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Standalone Download | 📦[Standalone, 32-bit](https://github.com/felixrieseberg/windows95/releases/download/v1.4.0/windows95-1.4.0-win32-standalone-ia32.zip) <br /> 📦[Standalone, 64-bit](https://github.com/felixrieseberg/windows95/releases/download/v1.4.0/windows95-1.4.0-win32-standalone-x64.zip) | 📦[Standalone](https://github.com/felixrieseberg/windows95/releases/download/v1.4.0/windows95-macos-1.4.0.zip) | |
| Installer | 💽[Setup, 64-bit](https://github.com/felixrieseberg/windows95/releases/download/v1.4.0/windows95-1.4.0-setup-win32-x64.exe) <br /> 💽[Setup, 32-bit](https://github.com/felixrieseberg/windows95/releases/download/v1.4.0/windows95-1.4.0-setup-win32-ia32.exe) | | 💽[deb, 64-bit](https://github.com/felixrieseberg/windows95/releases/download/v1.4.0/windows95-linux-1.4.0_amd64.deb) <br /> 💽[rpm, 64-bit](https://github.com/felixrieseberg/windows95/releases/download/v1.4.0/windows95-linux-1.4.0.x86_64.rpm) |
| Standalone Download | 📦[Standalone, 32-bit](https://github.com/felixrieseberg/windows95/releases/download/v2.0.0/windows95-2.0.0-win32-standalone-ia32.zip) <br /> 📦[Standalone, 64-bit](https://github.com/felixrieseberg/windows95/releases/download/v2.0.0/windows95-2.0.0-win32-standalone-x64.zip) | 📦[Standalone](https://github.com/felixrieseberg/windows95/releases/download/v2.0.0/windows95-macos-2.0.0.zip) | |
| Installer | 💽[Setup, 64-bit](https://github.com/felixrieseberg/windows95/releases/download/v2.0.0/windows95-2.0.0-setup-win32-x64.exe) <br /> 💽[Setup, 32-bit](https://github.com/felixrieseberg/windows95/releases/download/v2.0.0/windows95-2.0.0-setup-win32-ia32.exe) | | 💽[deb, 64-bit](https://github.com/felixrieseberg/windows95/releases/download/v2.0.0/windows95-linux-2.0.0_amd64.deb) <br /> 💽[rpm, 64-bit](https://github.com/felixrieseberg/windows95/releases/download/v2.0.0/windows95-linux-2.0.0.x86_64.rpm) |
![Screenshot](https://user-images.githubusercontent.com/1426799/44532591-4ceb3680-a6a8-11e8-8c2c-bc29f3bfdef7.png)
## Does it work?
Yes! Quite well, actually - on macOS, Windows, and Linux.
Yes! Quite well, actually - on macOS, Windows, and Linux. Bear in mind that this is written entirely in JavaScript, so please adjust your expectations.
## Should this have been a native app?
Absolutely.
@@ -23,9 +21,6 @@ You'll likely be better off with an actual virtualization app, but the short ans
@DisplacedGamers](https://youtu.be/xDXqmdFxofM) I can recommend that you switch to a resolution of
640x480 @ 256 colors before starting DOS games - just like in the good ol' days.
## How's the code?
This only works well by accident and was mostly a joke. The code quality is accordingly. Thus it should not be used for anything other than personal amusement.
## Credits
99.999% of the work was done over at [v86](https://github.com/copy/v86/) by Copy.
@@ -46,7 +41,11 @@ Once you've done so, run `npm install` and `npm start` to run your local build.
## Other Questions
* [MS-DOS seems to brick the screen](./HELP.md#ms-dos-seems-to-brick-the-screen)
* [Windows 95 is stuck in a bad state](./HELP.md#windows-95-is-stuck-in-a-bad-state)
* [I want to install additional apps or games](./HELP.md#i-want-to-install-additional-apps-or-games)
* [Running in Docker](./docs/docker-instructions.md)
* [Running in an online VM with Kubernetes and Gitpod](./docs/docker-kubernetes-gitpod.md)
## License

View File

@@ -27,7 +27,13 @@ Note: You may need to run `xhost +` on your system to allow connections to the X
* [XQuartz](https://www.xquartz.org/)
* [Docker](http://docker.io)
1. Start XQuartz ,go to "Preferences -> Security " ,and check the box "allow connections from network clients"
2. restart XQuartz
3. In the terminal ,run "xhost +"
4. run "docker run -it -e DISPLAY=host.docker.internal:1 toolboc/windows95"
1. Start XQuartz, go to `Preferences` -> `Security`, and check the box `Allow connections from network clients`
2. Restart XQuartz
3. In the terminal, run
```
xhost +
```
4. run
```
docker run -it -e DISPLAY=host.docker.internal:1 toolboc/windows95
```

View File

@@ -0,0 +1,4 @@
## Running an online version of windows95
You can also run windows95 in Electron, in a virtual X server, in a JavaScript VNC client, in a Kubernetes workspace. What could go wrong?
[![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/#https://github.com/felixrieseberg/windows95)

View File

@@ -3,9 +3,7 @@ const package = require('./package.json');
module.exports = {
packagerConfig: {
asar: {
unpack: '**/images/*.img'
},
asar: false,
icon: path.resolve(__dirname, 'assets', 'icon'),
appBundleId: 'com.felixrieseberg.windows95',
appCategoryType: 'public.app-category.developer-tools',
@@ -37,7 +35,7 @@ module.exports = {
},
{
name: '@electron-forge/maker-zip',
platforms: ['darwin']
platforms: ['darwin', 'win32']
},
{
name: '@electron-forge/maker-deb',
@@ -46,10 +44,19 @@ module.exports = {
{
name: '@electron-forge/maker-rpm',
platforms: ['linux']
},
}
],
publishers: [
{
name: '@electron-forge/maker-flatpak',
platforms: ['linux']
name: '@electron-forge/publisher-github',
config: {
repository: {
owner: 'felixrieseberg',
name: 'windows95'
},
draft: true,
prerelease: true
}
}
]
};

2292
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -1,7 +1,7 @@
{
"name": "windows95",
"productName": "windows95",
"version": "1.5.0",
"version": "2.1.0",
"description": "Windows 95, in an app. I'm sorry.",
"main": "src/index.js",
"scripts": {
@@ -29,18 +29,19 @@
},
"dependencies": {
"electron-squirrel-startup": "^1.0.0",
"fs-extra": "^7.0.1",
"fs-extra": "^8.0.1",
"update-electron-app": "^1.3.0"
},
"devDependencies": {
"@electron-forge/cli": "^6.0.0-beta.32",
"@electron-forge/maker-deb": "^6.0.0-beta.32",
"@electron-forge/maker-flatpak": "^6.0.0-beta.32",
"@electron-forge/maker-rpm": "^6.0.0-beta.32",
"@electron-forge/maker-squirrel": "^6.0.0-beta.32",
"@electron-forge/maker-zip": "^6.0.0-beta.32",
"electron": "4.0.4",
"node-abi": "^2.6.0",
"@electron-forge/cli": "^6.0.0-beta.34",
"@electron-forge/maker-deb": "^6.0.0-beta.34",
"@electron-forge/maker-flatpak": "^6.0.0-beta.34",
"@electron-forge/maker-rpm": "^6.0.0-beta.34",
"@electron-forge/maker-squirrel": "^6.0.0-beta.34",
"@electron-forge/maker-zip": "^6.0.0-beta.34",
"@electron-forge/publisher-github": "^6.0.0-beta.34",
"electron": "5.0.1",
"node-abi": "^2.8.0",
"standard": "^12.0.1"
}
}

View File

@@ -4,7 +4,14 @@ const path = require('path')
const ES6_PATH = path.join(__dirname, 'renderer')
protocol.registerStandardSchemes(['es6'])
protocol.registerSchemesAsPrivileged([
{
scheme: 'es6',
privileges: {
standard: true
}
}
])
async function setupProtocol () {
protocol.registerBufferProtocol('es6', async (req, cb) => {