Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
f03b59a
upgrade to electron 17.2, handle errors from unconfigured plugins gra…
sdetweil May 20, 2022
4db9f46
fix package.json for jsonform url
sdetweil May 20, 2022
1821ac5
fix formatting of new pm2 check code
sdetweil May 20, 2022
06615b2
add test for online status for PM2 process detection
sdetweil May 21, 2022
d9e6915
fix giphy and xkcd for api changes
sdetweil May 24, 2022
3d0dd29
add services and notifications from calednar, weather, clock
sdetweil Sep 29, 2022
06e9c8c
fixup services for broadcast status or data
sdetweil Oct 15, 2022
6ee7004
fix for server broadcasts
sdetweil Oct 15, 2022
5622dc3
sync to vnext and electron 17
sdetweil Oct 15, 2022
6710123
bring up to node 18
sdetweil Jan 6, 2024
120fc2d
move some dev dependencies to regular dependencies
sdetweil Jan 6, 2024
50da7f9
Merge branch 'n-w-electron' into dev
sdetweil Jan 6, 2024
6cf8f5d
add support for connecting thru mqtt to home assistant
sdetweil Mar 6, 2024
a1293ec
change version number
sdetweil Apr 6, 2024
4db1364
update mqtt to use ip address and machine name
sdetweil Apr 10, 2024
be98b97
clear scope for rss to prevent error if none
sdetweil Apr 10, 2024
dca9403
add recovery when mqtt broker dies
sdetweil Apr 14, 2024
f2dca12
Merge remote-tracking branch 'refs/remotes/origin/w_mqtt' into w_mqtt
sdetweil Apr 14, 2024
18f7c5f
pass any commandline parms, fix mqtt reconnect if broker dies
sdetweil Apr 14, 2024
81d9ab2
fix missing ip (network address) lib
sdetweil Apr 14, 2024
5bce7d0
fix summary formatting with embedded new lines
sdetweil Apr 21, 2024
5f9f975
fix mqtt broker failure reconnect
sdetweil Apr 28, 2024
62e6b77
fix subscribe recovery and subscribe topic by machine name
sdetweil Apr 30, 2024
089c52e
fix cal entry formatting with \; and mqtt recovery if broker goes down
sdetweil May 3, 2024
ea82d8b
force openweather to v3 api key as only choice in may 2024
sdetweil May 5, 2024
dcf67f4
upgrade to electron 31, disable gpu
sdetweil Jul 2, 2024
4d7075e
add github workflow
sdetweil Nov 12, 2024
7e7c49e
add the package.lock required by github actions
sdetweil Nov 27, 2024
4ef7364
update, remove bower
sdetweil Nov 27, 2024
8511a28
fix all page html to replace bower links with node_modules
sdetweil Nov 27, 2024
386c911
cleanup add dependabot.yml
sdetweil Dec 1, 2024
3d41a92
Merge branch 'master' into all-package.json
sdetweil Dec 1, 2024
09db74b
Delete .github/workflows/electron-rebuild.yaml
sdetweil Dec 1, 2024
2d04407
Update spellcheck.yaml
sdetweil Dec 1, 2024
63c728f
Update automated-tests.yaml
sdetweil Dec 1, 2024
91c76e6
Delete .github/workflows/dep-review.yaml
sdetweil Dec 1, 2024
7fd28fa
Delete scripts/pm2_smart-mirror.json
sdetweil Dec 1, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/dependabot.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "weekly"
target-branch: "dev"
labels:
- "Skip Changelog"
- "dependencies"
42 changes: 42 additions & 0 deletions .github/workflows/automated-tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: "Run Automated Tests"

on:
push:
branches: [master, dev]
pull_request:
branches: [master, dev]

permissions:
contents: read

jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
matrix:
node-version: [20.9.0, 20.x, 22.x, 23.x]
steps:
- name: "Checkout code"
uses: actions/checkout@v4
- name: "Use Node.js ${{ matrix.node-version }}"
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
check-latest: true
cache: "npm"
- name: "Install dependencies"
run: |
npm install --omit=dev
- name: "Run tests"
run: |
Xvfb :99 -screen 0 1024x768x16 &
export DISPLAY=:99
touch app/css/local.css
#npm run test:prettier
#npm run test:js
#npm run test:css
#npm run test
28 changes: 28 additions & 0 deletions .github/workflows/enforce-pullrequest-rules.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# This workflow enforces on every pull request:
# - the update of our CHANGELOG.md file, see: https://github.com/dangoslen/changelog-enforcer
# - that the PR is not based against master, taken from https://github.com/oppia/oppia-android/pull/2832/files

name: "Enforce Pull-Request Rules"

on:
pull_request_target:
types: [opened, synchronize, reopened, ready_for_review, labeled, unlabeled]

jobs:
check:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: "Enforce changelog"
uses: dangoslen/changelog-enforcer@v3
with:
changeLogPath: "CHANGELOG.md"
skipLabels: "Skip Changelog"
- name: "Enforce develop branch"
if: ${{ github.event.pull_request.base.ref == 'master' && !contains(github.event.pull_request.labels.*.name, 'mastermerge') }}
run: |
echo "This PR is based against the master branch and not a release or hotfix."
echo "Please don't do this. Switch the branch to 'develop'."
exit 1
env:
BASE_BRANCH: ${{ github.event.pull_request.base.ref }}
31 changes: 31 additions & 0 deletions .github/workflows/spellcheck.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# This workflow will run a spellcheck on the codebase.
# It runs a few days before each release. At 00:00 on day-of-month 27 in March, June, September, and December.

name: Run Spellcheck

on:
schedule:
- cron: "0 0 27 3,6,9,12 *"

permissions:
contents: read

jobs:
spellcheck:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: develop
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "22"
check-latest: true
cache: "npm"
- name: Install dependencies
run: |
npm run install
- name: Run Spellcheck
run: npm run test:spellcheck
22 changes: 22 additions & 0 deletions .github/workflows/stale.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: "Close stale issues and PRs"

on:
workflow_dispatch: # needed for manually running this workflow
schedule:
- cron: "30 1 * * 6" # every Saturday at 1:30

permissions:
issues: write

jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v9
with:
stale-issue-message: "This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions."
days-before-issue-stale: 60
days-before-issue-close: 7
operations-per-run: 100
stale-issue-label: "wontfix"
exempt-issue-labels: "pinned,security,under investigation,pr welcome"
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,11 @@ jsonform
spotify-token.json
main_index.html
motion
package-lock.json
#package-lock.json
app/locales/??c.json
app/css/local.css
.gitignore
.prettierrc
.editorconfig
plugins/
!.gitkeep
32 changes: 32 additions & 0 deletions .gitkeep
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
plugins/autosleep
plugins/calendar
plugins/commands
plugins/commitstrip
plugins/datetime
plugins/dilbert
plugins/fitbit
plugins/_general
plugins/geolocation
plugins/giphy
plugins/greeting
plugins/ha-display
plugins/light
plugins/maker
plugins/map
plugins/pluginconfig
plugins/reminder
plugins/remote
plugins/rss
plugins/scrobbler
plugins/search
plugins/soundcloud
plugins/speech
plugins/spotify
plugins/stock
plugins/timebox
plugins/timer
plugins/todoist
plugins/traffic
plugins/tvshows
plugins/weather
plugins/xkcd
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@ Everybody is invited and welcome to contribute to the Smart Mirror. There is a l

The process is straight-forward.

- Fork Smart Mirror [git repository](https://github.com/evancohen/smart-mirror).
- Fork Smart Mirror [git repository](https://github.com/sdetweil/smart-mirror).
- Write the code for your feature/capability.
- Create a Pull Request against the [**dev**](https://github.com/evancohen/smart-mirror/tree/dev) branch of the Smart Mirror.
- Create a Pull Request against the [**dev**](https://github.com/sdetweil/smart-mirror/tree/dev) branch of the Smart Mirror.
19 changes: 13 additions & 6 deletions app/css/newfile.css
Original file line number Diff line number Diff line change
@@ -1,24 +1,31 @@
:root{
--scale-factor: 1; /* set default scaling in case we have partial window, debug or in vm terminal window */
--design-width: 1920px;
--design-height: 1080px;
}

@media screen and (width:1920px) and (orientation: landscape) {
@media screen and (orientation: landscape) {
:root{
--scale-factor: 1920/1920;
--scale-factor: var(width) / var(--design-width);
};
}
@media screen and (orientation: portrait) {
:root{
--scale-factor: var(width) / var(--design-height);
};
}

@media screen and (width:3840px) and (orientation: landscape) {
/*@media screen and (width:3840px) and (orientation: landscape) {
:root{
--scale-factor: 3840/1920;
--scale-factor: width/var(--design-width);

};
}
@media screen and (width:1080px) {
:root{
--scale-factor: 1920/1920;
--scale-factor: width/var(--design-width);
};
}
}*/



Expand Down
2 changes: 1 addition & 1 deletion app/js/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
.config(function (tmhDynamicLocaleProvider) {
console.log(config);
tmhDynamicLocaleProvider.localeLocationPattern(
"bower_components/angular-i18n/angular-locale_" +
"node_modules/angular-i18n/angular-locale_" +
language +
".js"
);
Expand Down
13 changes: 4 additions & 9 deletions app/js/controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
function MirrorCtrl(
Focus,
SpeechService,
MQTTService,
AutoSleepService,
// LightService,
$rootScope,
$scope,
$timeout,
Expand Down Expand Up @@ -48,6 +48,7 @@

var resetCommandTimeout;
var listeningTimeout;
MQTTService.start();
SpeechService.init({
listening: function (listening) {
$scope.listening = listening;
Expand Down Expand Up @@ -93,6 +94,7 @@
$scope.focus = AutoSleepService.scope;
AutoSleepService.startAutoSleepTimer();
}
$rootScope.$broadcast("clock-tick",$scope.date)
}
var clearListening = function(){
$scope.listening = false;
Expand Down Expand Up @@ -183,17 +185,10 @@
console.debug("It is", moment().format("h:mm:ss a"));
});

// Control light
/* SpeechService.addCommand("light_action", function (
state,
target,
action
) {
LightService.performUpdate([state, target, action].join(" "));
}); */
};

_this.init();

}

angular.module("SmartMirror").controller("MirrorCtrl", MirrorCtrl);
Expand Down
40 changes: 0 additions & 40 deletions bower.json

This file was deleted.

21 changes: 9 additions & 12 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@
<link href='https://fonts.googleapis.com/css?family=Open+Sans:300,400,600,800,700' rel='stylesheet' type='text/css'>
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link rel="stylesheet" ng-href="app/css/{{ layoutName }}.css" />
<!-- bower:css -->
<!-- endbower -->


</head>

Expand Down Expand Up @@ -58,16 +57,14 @@
==========================================================================
The good stuff. -->

<!-- bower:js -->
<script src="bower_components/moment/min/moment-with-locales.js"></script>
<script src="bower_components/angular/angular.js"></script>
<script src="bower_components/angular-animate/angular-animate.js"></script>
<script src="bower_components/angular-dynamic-locale/dist/tmhDynamicLocale.js"></script>
<script src="bower_components/angular-translate/angular-translate.js"></script>
<script src="bower_components/angular-translate-loader-static-files/angular-translate-loader-static-files.js"></script>
<script src="bower_components/rrule/lib/rrule.js"></script>
<script src="bower_components/skycons/skycons.js"></script>
<!-- endbower -->
<script src="node_modules/moment/min/moment-with-locales.js"></script>
<script src="node_modules/angular/angular.js"></script>
<script src="node_modules/angular-animate/angular-animate.js"></script>
<script src="node_modules/angular-dynamic-locale/dist/tmhDynamicLocale.js"></script>
<script src="node_modules/angular-translate/dist/angular-translate.js"></script>
<script src="node_modules/angular-translate-loader-static-files/angular-translate-loader-static-files.js"></script>
<script src="node_modules/rrule/lib/rrule.js"></script>
<script src="node_modules/skycons/skycons.js"></script>

<script src="https://connect.soundcloud.com/sdk/sdk-3.0.0.js"></script>

Expand Down
21 changes: 9 additions & 12 deletions logging_index.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@
<link href='https://fonts.googleapis.com/css?family=Open+Sans:300,400,600,800,700' rel='stylesheet' type='text/css'>
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link rel="stylesheet" ng-href="app/css/{{ layoutName }}.css" />
<!-- bower:css -->
<!-- endbower -->


</head>

Expand Down Expand Up @@ -60,16 +59,14 @@
==========================================================================
The good stuff. -->

<!-- bower:js -->
<script src="bower_components/moment/min/moment-with-locales.js"></script>
<script src="bower_components/angular/angular.js"></script>
<script src="bower_components/angular-animate/angular-animate.js"></script>
<script src="bower_components/angular-dynamic-locale/dist/tmhDynamicLocale.js"></script>
<script src="bower_components/angular-translate/angular-translate.js"></script>
<script src="bower_components/angular-translate-loader-static-files/angular-translate-loader-static-files.js"></script>
<script src="bower_components/rrule/lib/rrule.js"></script>
<script src="bower_components/skycons/skycons.js"></script>
<!-- endbower -->
<script src="node_modules/moment/min/moment-with-locales.js"></script>
<script src="node_modules/angular/angular.js"></script>
<script src="node_modules/angular-animate/angular-animate.js"></script>
<script src="node_modules/angular-dynamic-locale/dist/tmhDynamicLocale.js"></script>
<script src="node_modules/angular-translate/dist/angular-translate.js"></script>
<script src="node_modules/angular-translate-loader-static-files/angular-translate-loader-static-files.js"></script>
<script src="node_modules/rrule/lib/rrule.js"></script>
<script src="node_modules/skycons/skycons.js"></script>

<script src="https://connect.soundcloud.com/sdk/sdk-3.0.0.js"></script>

Expand Down
Loading