Installer humble-games-collection-windows

files:
- ags: https://www.humblebundle.com/app/download
game:
  arch: win64
  args: --in-process-gpu
  exe: start-humble.cmd
  prefix: $GAMEDIR
install_complete_text: 'Installation complete.


  After allowing access from your browser, you should open the link with the "Humble
  Games Collection (Login)" app.'
installer:
- task:
    arch: win64
    name: create_prefix
    prefix: $GAMEDIR
- task:
    arch: win64
    args: /S
    exclude_processes: Humble App.exe explorer.exe
    executable: ags
    name: wineexec
    prefix: $GAMEDIR
- write_file:
    content: '#!/usr/bin/env sh

      set -e

      export LUTRIS_SKIP_INIT=1

      LUTRIS_CMD="lutris:rungame/humble-games-collection"

      FIXED_SCHEME="$(echo "$1" | sed "s/?/\//")"


      echo "$FIXED_SCHEME" > $GAMEDIR/drive_c/.auth

      if command -v lutris 1>/dev/null; then

      lutris $LUTRIS_CMD

      else

      flatpak run net.lutris.Lutris $LUTRIS_CMD

      fi'
    file: $GAMEDIR/handle-humble-scheme
- chmodx: $GAMEDIR/handle-humble-scheme
- write_file:
    content: '@echo off

      cd /d "%USERPROFILE%\AppData\Local\Programs\Humble App\"

      set /p Url=<"C:\.auth"

      if defined Url (

      start "" "Humble App.exe" "%Url%"

      del "C:\.auth"

      ) else (

      start "" "Humble App.exe" "%*"

      )'
    file: $GAMEDIR/start-humble.cmd
- write_file:
    content: '[Desktop Entry]

      Name=Humble Games Collection (Login)

      Comment=Target for handling Humble Games Collection logins. You should not run
      this manually.

      Exec=$GAMEDIR/handle-humble-scheme %u

      Type=Application

      Icon=lutris_humble-games-collection

      MimeType=x-scheme-handler/humble;'
    file: $HOME/.local/share/applications/Humble-scheme-handler.desktop
description: ''
game_slug: humble-games-collection
gogslug: ''
humblestoreid: ''
installer_slug: humble-games-collection-windows
name: Humble Games Collection
notes: "After allowing access to your account in the browser, if prompted for which\
  \ application to handle `humble:` link in, you should select the `Humble Games Collection\
  \ (Login)` application.\r\n\r\nUsually running `xdg-mime default Humble-scheme-handler.desktop\
  \ x-scheme-handler/humble` in your terminal should tell your browser to handle `humble:`\
  \ links in that application without asking.\r\n\r\nIf that still doesn't work, you\
  \ should open an issue in [https://github.com/Gustash/lutris_installers] so I can\
  \ help you debug the issue."
runner: wine
script:
  files:
  - ags: https://www.humblebundle.com/app/download
  game:
    arch: win64
    args: --in-process-gpu
    exe: start-humble.cmd
    prefix: $GAMEDIR
  install_complete_text: 'Installation complete.


    After allowing access from your browser, you should open the link with the "Humble
    Games Collection (Login)" app.'
  installer:
  - task:
      arch: win64
      name: create_prefix
      prefix: $GAMEDIR
  - task:
      arch: win64
      args: /S
      exclude_processes: Humble App.exe explorer.exe
      executable: ags
      name: wineexec
      prefix: $GAMEDIR
  - write_file:
      content: '#!/usr/bin/env sh

        set -e

        export LUTRIS_SKIP_INIT=1

        LUTRIS_CMD="lutris:rungame/humble-games-collection"

        FIXED_SCHEME="$(echo "$1" | sed "s/?/\//")"


        echo "$FIXED_SCHEME" > $GAMEDIR/drive_c/.auth

        if command -v lutris 1>/dev/null; then

        lutris $LUTRIS_CMD

        else

        flatpak run net.lutris.Lutris $LUTRIS_CMD

        fi'
      file: $GAMEDIR/handle-humble-scheme
  - chmodx: $GAMEDIR/handle-humble-scheme
  - write_file:
      content: '@echo off

        cd /d "%USERPROFILE%\AppData\Local\Programs\Humble App\"

        set /p Url=<"C:\.auth"

        if defined Url (

        start "" "Humble App.exe" "%Url%"

        del "C:\.auth"

        ) else (

        start "" "Humble App.exe" "%*"

        )'
      file: $GAMEDIR/start-humble.cmd
  - write_file:
      content: '[Desktop Entry]

        Name=Humble Games Collection (Login)

        Comment=Target for handling Humble Games Collection logins. You should not
        run this manually.

        Exec=$GAMEDIR/handle-humble-scheme %u

        Type=Application

        Icon=lutris_humble-games-collection

        MimeType=x-scheme-handler/humble;'
      file: $HOME/.local/share/applications/Humble-scheme-handler.desktop
slug: humble-games-collection-windows
steamid: null
version: Windows
year: 2021
{
  "game_slug": "humble-games-collection",
  "version": "Windows",
  "description": "",
  "notes": "After allowing access to your account in the browser, if prompted for which application to handle `humble:` link in, you should select the `Humble Games Collection (Login)` application.\r\n\r\nUsually running `xdg-mime default Humble-scheme-handler.desktop x-scheme-handler/humble` in your terminal should tell your browser to handle `humble:` links in that application without asking.\r\n\r\nIf that still doesn't work, you should open an issue in [https://github.com/Gustash/lutris_installers] so I can help you debug the issue.",
  "name": "Humble Games Collection",
  "year": 2021,
  "steamid": null,
  "gogslug": "",
  "humblestoreid": "",
  "runner": "wine",
  "slug": "humble-games-collection-windows",
  "installer_slug": "humble-games-collection-windows",
  "script": {
    "files": [
      {
        "ags": "https://www.humblebundle.com/app/download"
      }
    ],
    "game": {
      "arch": "win64",
      "args": "--in-process-gpu",
      "exe": "start-humble.cmd",
      "prefix": "$GAMEDIR"
    },
    "install_complete_text": "Installation complete.\n\nAfter allowing access from your browser, you should open the link with the \"Humble Games Collection (Login)\" app.",
    "installer": [
      {
        "task": {
          "arch": "win64",
          "name": "create_prefix",
          "prefix": "$GAMEDIR"
        }
      },
      {
        "task": {
          "arch": "win64",
          "args": "/S",
          "exclude_processes": "Humble App.exe explorer.exe",
          "executable": "ags",
          "name": "wineexec",
          "prefix": "$GAMEDIR"
        }
      },
      {
        "write_file": {
          "content": "#!/usr/bin/env sh\nset -e\nexport LUTRIS_SKIP_INIT=1\nLUTRIS_CMD=\"lutris:rungame/humble-games-collection\"\nFIXED_SCHEME=\"$(echo \"$1\" | sed \"s/?/\\//\")\"\n\necho \"$FIXED_SCHEME\" > $GAMEDIR/drive_c/.auth\nif command -v lutris 1>/dev/null; then\nlutris $LUTRIS_CMD\nelse\nflatpak run net.lutris.Lutris $LUTRIS_CMD\nfi",
          "file": "$GAMEDIR/handle-humble-scheme"
        }
      },
      {
        "chmodx": "$GAMEDIR/handle-humble-scheme"
      },
      {
        "write_file": {
          "content": "@echo off\ncd /d \"%USERPROFILE%\\AppData\\Local\\Programs\\Humble App\\\"\nset /p Url=<\"C:\\.auth\"\nif defined Url (\nstart \"\" \"Humble App.exe\" \"%Url%\"\ndel \"C:\\.auth\"\n) else (\nstart \"\" \"Humble App.exe\" \"%*\"\n)",
          "file": "$GAMEDIR/start-humble.cmd"
        }
      },
      {
        "write_file": {
          "content": "[Desktop Entry]\nName=Humble Games Collection (Login)\nComment=Target for handling Humble Games Collection logins. You should not run this manually.\nExec=$GAMEDIR/handle-humble-scheme %u\nType=Application\nIcon=lutris_humble-games-collection\nMimeType=x-scheme-handler/humble;",
          "file": "$HOME/.local/share/applications/Humble-scheme-handler.desktop"
        }
      }
    ]
  }
}
Back to game