Skip to content
This repository has been archived by the owner on Jun 8, 2023. It is now read-only.

Add information about scripts with package replacements #1696

Merged
merged 9 commits into from
May 6, 2016

Conversation

technicalpickles
Copy link
Contributor

This is code to go along with #1641 . I've added a replacements.json in the root with a map of scripts to homepages of extracted scripts. Then there's a helper in src/hubot-scripts.coffee to actually deprecate a script.

There are a number of deprecated scripts already, so I've updated one of them to use this helper, but if it looks good, will apply to others.

Another approach I was considering was moving some or all of this into hubot's core. One thought was that can do it right before requiring, rather than as it's being required, so scripts wouldn't need to be modified.

cc @github/open-source-hubot-maintainers

@technicalpickles
Copy link
Contributor Author

Was talking to @bkeepers about this earlier, and he was starting work on a script to search GitHub for possible replacements. That got me to thinking that we could just prompt users to search Google, GitHub, and NPM for packages if there isn't a replacement, and to post back on #1641.

If we are doing that, then it's probably not worth updating every script to have the deprecate logic. Given that, this is probably easier to have in github/hubot. The downside is the data about replacements is in that repo, and requires hubot releases to update. That might not be so bad though.

@technicalpickles
Copy link
Contributor Author

A few months ago in hubotio/hubot#970 I added support for checking repalcements.json that I started before this branch. I expanded on that to check for the replacements.json, and if it's not present, prompt to install a newer version of hubot-scripts that includes it. If it is present, and there's scripts that don't have replacements, there's a recommendation to update for a more recent version that maybe has more replacements.

That makes this PR just the replacements.json, and to remove manual deprecation some scripts had. There is whitespace relatated diffs too, but those can be ignored.

@technicalpickles technicalpickles changed the title Programmatically deprecate scripts Add information about scripts with package replacements May 6, 2016
@technicalpickles technicalpickles merged commit 034ce49 into master May 6, 2016
@technicalpickles technicalpickles deleted the deprecated branch May 6, 2016 22:37
@technicalpickles technicalpickles mentioned this pull request May 6, 2016
@technicalpickles technicalpickles restored the deprecated branch May 6, 2016 22:42
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant