Est-il possible de télécharger une plate-forme de bijou spécifique Ruby sans l'installer?
Question
Je lis une réponse la réponse gem fetch
sur cette question est-il possible-à-télécharger un rubis-gem-sans-installation-it-automatiquement . Mais les fenêtres je ne suis pas toujours la pierre précieuse de fenêtres.
Utilisation gem install gosu --remote
installe la version Windows Successfully installed gosu-0.7.15-x86-mswin32-60
.
Lors du téléchargement en utilisant gem fetch gosu
je reçois Downloaded gosu-0.7.15
qui est la version linux et ne peut pas être installé sur mon PC Windows.
Demander le joyau spécifique avec gem fetch gosu-0.7.15-x86-mswin32-60
et essais similaires donne ERROR: Could not find gosu-0.7.15-x86-mswin32-60 in any repository
Toutes les idées sur la façon d'obtenir la version correcte pour mon PC lors de l'utilisation par rapport à l'installation chercher?
La solution
$ gem fetch --help
Usage: gem fetch GEMNAME [GEMNAME ...] [options]
Options:
-v, --version VERSION Specify version of gem to fetch
--platform PLATFORM Specify the platform of gem to fetch
Local/Remote Options:
-B, --bulk-threshold COUNT Threshold for switching to bulk
synchronization (default 1000)
-p, --[no-]http-proxy [URL] Use HTTP proxy for remote operations
--source URL Use URL as the remote source for gems
Common Options:
-h, --help Get help on this command
-V, --[no-]verbose Set the verbose level of output
-q, --quiet Silence commands
--config-file FILE Use this config file instead of default
--backtrace Show stack backtrace on errors
--debug Turn on Ruby debugging
Arguments:
GEMNAME name of gem to download
Summary:
Download a gem and place it in the current directory
Defaults:
--version '>= 0'
Vous devriez être en mesure de le faire
$ gem fetch gosu --platform x86-mswin32
Ou tout simplement aller à la page de téléchargement .