• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
MagicMirror Forum
  • Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
A New Chapter for MagicMirror: The Community Takes the Lead
Read the statement by Michael Teeuw here.

Automatic checking of all MagicMirror² modules

Scheduled Pinned Locked Moved Development
83 Posts 9 Posters 57.4k Views 10 Watching
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    Jalibu Module Developer @KristjanESPERANTO
    last edited by Nov 12, 2023, 11:47 AM

    @KristjanESPERANTO said in Automatic checking of all MagicMirror² modules:

    @mumblebaj said in Automatic checking of all MagicMirror² modules:

    Just out of interest, which image does it select as the thumbnail?

    If the script doesn’t find an image with ‘screenshot’ or ‘example’ at the beginning of the name it takes the first it finds .

    Hi @KristjanESPERANTO does it expect the example.png in a specific folder (such as img/ or /) or can it also lookup in docs/?

    K 1 Reply Last reply Nov 12, 2023, 3:52 PM Reply Quote 0
    • S Offline
      sdetweil @KristjanESPERANTO
      last edited by Nov 12, 2023, 12:01 PM

      @KristjanESPERANTO and, this impacts my scripts as i use package.json as the indicator for doing an npm install in the module folder.

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      K 1 Reply Last reply Nov 12, 2023, 4:02 PM Reply Quote 0
      • K Offline
        KristjanESPERANTO Module Developer @Jalibu
        last edited by Nov 12, 2023, 3:52 PM

        @Jalibu said in Automatic checking of all MagicMirror² modules:

        Hi @KristjanESPERANTO does it expect the example.png in a specific folder (such as img/ or /) or can it also lookup in docs/?

        No, you can put it where ever you want :-)

        1 Reply Last reply Reply Quote 0
        • K Offline
          KristjanESPERANTO Module Developer @sdetweil
          last edited by Nov 12, 2023, 4:02 PM

          @sdetweil said in Automatic checking of all MagicMirror² modules:

          @KristjanESPERANTO and, this impacts my scripts as i use package.json as the indicator for doing an npm install in the module folder.

          There are some modules that only have devDependencies, so your script already makes unnecessary npm install calls. Can you adjust your trigger and check whether dependencies are set in the package.json?

          S 1 Reply Last reply Nov 13, 2023, 3:26 PM Reply Quote 0
          • M Offline
            MZ-BER
            last edited by Nov 13, 2023, 9:09 AM

            Great work @KristjanESPERANTO. Really, really like this. Is there a way to also publish the github stars and # of forks? I also would love if there is a way to “like” a module.

            1 Reply Last reply Reply Quote 1
            • M Offline
              MMRIZE
              last edited by MMRIZE Nov 13, 2023, 9:31 AM Nov 13, 2023, 9:28 AM

              I suggest you and the community expand package.json to regularise the details of the module. (recommended but optional)
              For example;

              {
                "name": "mmm-something",
                "version": "1.0.0",
                ...
                "mm" : {
                  "communityId" : "johndoe",
                  "community" : "MagicMirror forum",
                  "screenshot" : "https://somewhere.com/screenshot.png",
                  "install" : "https://github.com/johndoe/mmm-something/README.md#installation",
                  "update" : "...",
                  "email" : "johndoe@somewhere",
                  "required: {
                    "mm" : "2.25",
                    "node" : "18.0"
                  },
                  "notice" : [
                    "This will not work in Windows.",
                    "Pre-dependency required. Please readme."
                  ]
                }
              }
              

              The fields are my imagination. Maybe the community can reach an agreement on rules.

              1 Reply Last reply Reply Quote 2
              • M Offline
                mumblebaj Module Developer @KristjanESPERANTO
                last edited by Nov 13, 2023, 3:18 PM

                @KristjanESPERANTO My MMM-SweepClock doesn’t have a package.json either as all work done in the MMM-SweepClock.js file. I can add one for completeness and conformity. I also notice I did not have an image. I usually name my images image-1.png etc. so the main image is generally the first one.

                Check out my modules at: https://github.com/mumblebaj?tab=repositories

                1 Reply Last reply Reply Quote 0
                • S Offline
                  sdetweil @KristjanESPERANTO
                  last edited by Nov 13, 2023, 3:26 PM

                  @KristjanESPERANTO oh, and one more thing… my MMM-SleepWake module does not have any UI… so there is no photo…

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  K 1 Reply Last reply Nov 13, 2023, 9:30 PM Reply Quote 0
                  • K Offline
                    KristjanESPERANTO Module Developer @sdetweil
                    last edited by Nov 13, 2023, 9:30 PM

                    @MZ-BER said in Automatic checking of all MagicMirror² modules:

                    Great work @KristjanESPERANTO. Really, really like this. Is there a way to also publish the github stars and # of forks? I also would love if there is a way to “like” a module.

                    Thank you for your appreciation! :-)

                    karsten13 has already suggested the GitHub API and I have tested it, but if you make requests for 1000 modules you’ll got blocked quickly. I haven’t found another good approach yet.

                    @MMRIZE said in Automatic checking of all MagicMirror² modules:

                    I suggest you and the community expand package.json to regularise the details of the module. (recommended but optional)

                    Storing additional data in the package.json is an interesting idea! But I would like to avoid maintaining data redundantly. So before we tackle this, it would be good to have an overview of the data that is already used for the website and where it is taken from. Plus an additional list of data that is still needed, ideally with ideas on how to collect it. What’s not easy to implement could perhaps be addressed by extending the packge.json.

                    @mumblebaj said in Automatic checking of all MagicMirror² modules:

                    My MMM-SweepClock doesn’t have a package.json either as all work done in the MMM-SweepClock.js file. I can add one for completeness and conformity. I also notice I did not have an image. I usually name my images image-1.png etc. so the main image is generally the first one.

                    At the moment the script has no other source for keywords and the license. And without the license information no image will be taken. If you want an image to be displayed on the website, you would have to specify a free license in the package.json.

                    @sdetweil said in Automatic checking of all MagicMirror² modules:

                    my MMM-SleepWake module does not have any UI… so there is no photo…

                    There is no obligation for an image. But perhaps it would be nice to use an icon that symbolizes motion detection instead of a screenshot. Like this maybe: https://openclipart.org/detail/306403/motion-detection?

                    K 1 Reply Last reply Nov 20, 2023, 7:39 PM Reply Quote 0
                    • K Offline
                      karsten13 @KristjanESPERANTO
                      last edited by Nov 20, 2023, 7:39 PM

                      @KristjanESPERANTO said in Automatic checking of all MagicMirror² modules:

                      karsten13 has already suggested the GitHub API and I have tested it, but if you make requests for 1000 modules you’ll got blocked quickly. I haven’t found another good approach yet.

                      2 ideas:

                      • did you try to authenticate with a user before making the api requests? AFAIR we solved a similar problem at work with authentication …
                      • if first idea doesn’t work an ugly solution is to work with e.g. a timer or sleep statement because these infos are not changed very often this could be a long running nightly job
                      K 1 Reply Last reply Nov 21, 2023, 11:38 PM Reply Quote 2
                      • 1
                      • 2
                      • 3
                      • 4
                      • 5
                      • 6
                      • 7
                      • 8
                      • 9
                      • 5 / 9
                      5 / 9
                      • First post
                        44/83
                        Last post
                      Enjoying MagicMirror? Please consider a donation!
                      MagicMirror created by Michael Teeuw.
                      Forum managed by Sam, technical setup by Karsten.
                      This forum is using NodeBB as its core | Contributors
                      Contact | Privacy Policy