<?xml version="1.0" encoding="UTF-8"?>
<rdf:RDF xmlns="http://purl.org/rss/1.0/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel rdf:about="https://let.hatelabo.jp/den8/rss">
    <link>https://let.hatelabo.jp/den8/rss</link>
    <description></description>
    <title>Bookmarklets from den8</title>
    <items>
      <rdf:Seq>
        <rdf:li rdf:resource="https://let.hatelabo.jp/den8/let/kvPs5dXEguAA"/>
        <rdf:li rdf:resource="https://let.hatelabo.jp/den8/let/hLHVkfXVrtAa"/>
        <rdf:li rdf:resource="https://let.hatelabo.jp/den8/let/hLHUs4XMnKhl"/>
        <rdf:li rdf:resource="https://let.hatelabo.jp/den8/let/hJmdidqM7pAE"/>
        <rdf:li rdf:resource="https://let.hatelabo.jp/den8/let/hLHVhryxldMv"/>
        <rdf:li rdf:resource="https://let.hatelabo.jp/den8/let/gYC-yIG60MuCXQ"/>
        <rdf:li rdf:resource="https://let.hatelabo.jp/den8/let/hLHWlbSBnrIH"/>
      </rdf:Seq>
    </items>
  </channel>
  <item rdf:about="https://let.hatelabo.jp/den8/let/kvPs5dXEguAA">
    <link>https://let.hatelabo.jp/den8/let/kvPs5dXEguAA</link>
    <dc:date>2025-04-17T02:46:05Z</dc:date>
    <description>googleカレンダーの予定編集画面からpermalinkを作ります</description>
    <dc:creator>den8</dc:creator>
    <title>[Let] google calendarのpermalink作成</title>
    <content:encoded>&lt;a href="javascript:var%20result%3Dlocation.href.match%28%2Fhttps%3A%5C%2F%5C%2Fcalendar.google.com%5C%2Fcalendar%5C%2F.%2A%5C%2Feventedit%5C%2F%28%5B0-9a-zA-Z%5D%2B%29%2F%29%3Bif%28result%29%7Bprompt%28%22Ctrl-C%E3%81%A7%E3%82%B3%E3%83%94%E3%83%BC%E3%81%97%E3%81%A6%E3%81%8F%E3%81%A0%E3%81%95%E3%81%84%E3%80%82%22%2C%22https%3A%2F%2Fwww.google.com%2Fcalendar%2Fevent%3Feid%3D%22%2Bresult%5B1%5D%29%7Delse%20alert%28%22%E5%AF%BE%E5%BF%9C%E3%82%B5%E3%82%A4%E3%83%88%E3%81%A7%E3%81%AF%E3%81%82%E3%82%8A%E3%81%BE%E3%81%9B%E3%82%93%E3%80%82%22%29%3B"&gt;google calendarのpermalink作成&lt;/a&gt;&lt;pre&gt;/*
 * @title google calendarのpermalink作成
 * @description googleカレンダーの予定編集画面からpermalinkを作ります
 * @include https://calendar.google.com/
 * @license 悪さしなければ自由に使ってもらって構いません
 * @javascript_url
 *
 * 完成させてから気づいたが、 https://stackoverflow.com/a/25197219/4006322 にもっと定評のあるよい実装があった
 */

var result = location.href.match(/https:\/\/calendar.google.com\/calendar\/.*\/eventedit\/([0-9a-zA-Z]+)/);
if (result) {
  prompt(&amp;quot;Ctrl-Cでコピーしてください。&amp;quot;, &amp;quot;https://www.google.com/calendar/event?eid=&amp;quot; + result[1]);
} else alert(&amp;quot;対応サイトではありません。&amp;quot;);
&lt;/pre&gt;</content:encoded>
  </item>
  <item rdf:about="https://let.hatelabo.jp/den8/let/hLHVkfXVrtAa">
    <link>https://let.hatelabo.jp/den8/let/hLHVkfXVrtAa</link>
    <dc:date>2018-07-12T18:25:21Z</dc:date>
    <description>https://help.github.com/articles/getting-permanent-links-to-files/ githubサイト内で「y」を押すことによりURL中のブランチ名/タグ名をコミットハッシュに切り替えることができる。しかしこのとき置換されるコミットハッシュは40桁のフルサイズのもので共有するURLとしていささか長い。そこでほとんどのリポジトリで必要十分と思われる8桁のコミットハッシュに置換するのがこのブックマークレット。ついでにgithubの「y」ショートカットでの挙動はいささかおかしい(URLは書き換えるがブラウザのhistoryにそれを積まない)のでこのブックマークレットではきちんと置換後のURLへ遷移することにした。</description>
    <dc:creator>den8</dc:creator>
    <title>[Let] GithubでURL中のブランチ名/タグ名をコミットハッシュ(8桁)に置き換える</title>
    <content:encoded>&lt;a href="javascript:if%28location.host%3D%3D%3D%22github.com%22%29%7Bvar%20pathname%3Ddocument.querySelector%28%27a%5Bdata-hotkey%3D%22y%22%5D%27%29.getAttribute%28%22href%22%29%3Bvar%20parts%3Dpathname.split%28%22%2F%22%29%3Bparts%5B4%5D%3Dparts%5B4%5D.substring%280%2C8%29%3Blocation.pathname%3Dparts.join%28%22%2F%22%29%7D"&gt;GithubでURL中のブランチ名/タグ名をコミットハッシュ(8桁)に置き換える&lt;/a&gt;&lt;pre&gt;/*
 * @title GithubでURL中のブランチ名/タグ名をコミットハッシュ(8桁)に置き換える
 * @description https://help.github.com/articles/getting-permanent-links-to-files/ githubサイト内で「y」を押すことによりURL中のブランチ名/タグ名をコミットハッシュに切り替えることができる。しかしこのとき置換されるコミットハッシュは40桁のフルサイズのもので共有するURLとしていささか長い。そこでほとんどのリポジトリで必要十分と思われる8桁のコミットハッシュに置換するのがこのブックマークレット。ついでにgithubの「y」ショートカットでの挙動はいささかおかしい(URLは書き換えるがブラウザのhistoryにそれを積まない)のでこのブックマークレットではきちんと置換後のURLへ遷移することにした。
 * @include https://github.com/*
 * @license MIT License
 * @require 
 * @javascript_url
 */


if (location.host === &amp;quot;github.com&amp;quot;) {
  var pathname = document.querySelector('a[data-hotkey=&amp;quot;y&amp;quot;]').getAttribute(&amp;quot;href&amp;quot;);
  var parts = pathname.split(&amp;quot;/&amp;quot;);
  parts[4] = parts[4].substring(0, 8);
  location.pathname = parts.join(&amp;quot;/&amp;quot;);
}&lt;/pre&gt;</content:encoded>
  </item>
  <item rdf:about="https://let.hatelabo.jp/den8/let/hLHUs4XMnKhl">
    <link>https://let.hatelabo.jp/den8/let/hLHUs4XMnKhl</link>
    <dc:date>2018-07-12T17:45:09Z</dc:date>
    <description>Google検索結果から検索文字列以外の不要なクエリパラメータを削除</description>
    <dc:creator>den8</dc:creator>
    <title>[Let] Google検索結果URLを短縮</title>
    <content:encoded>&lt;a href="javascript:if%28location.host.includes%28%22www.google%22%29%29%7Bvar%20tmp%3Dlocation.href.split%28%22%3F%22%29%3Bvar%20fore%3Dtmp%5B0%5D%3Bvar%20queryString%3Dtmp%5B1%5D%3Bvar%20q%3DqueryString.split%28%22%26%22%29.find%28%28function%28elem%29%7Breturn%20elem.startsWith%28%22q%3D%22%29%7D%29%29%3Bif%28%21q%29alert%28%22queryString%E3%81%ABq%E3%81%8C%E3%81%82%E3%82%8A%E3%81%BE%E3%81%9B%E3%82%93%22%29%3Belse%7Bwindow.location.href%3Dfore%2B%22%3F%22%2Bq%7D%7Delse%20alert%28%22google%E6%A4%9C%E7%B4%A2%E3%81%AE%E3%83%9A%E3%83%BC%E3%82%B8%E3%81%A7%E3%81%AF%E3%81%AA%E3%81%95%E3%81%9D%E3%81%86%E3%81%A7%E3%81%99%21%22%29%3B"&gt;Google検索結果URLを短縮&lt;/a&gt;&lt;pre&gt;/*
 * @title Google検索結果URLを短縮
 * @description Google検索結果から検索文字列以外の不要なクエリパラメータを削除
 * @include http*://www.google.*
 * @license MIT License
 * @require
 * @javascript_url
 */


if (location.host.includes(&amp;quot;www.google&amp;quot;)) {
  var tmp = location.href.split(&amp;quot;?&amp;quot;);
  var fore = tmp[0];
  var queryString = tmp[1];
  var q = queryString.split(&amp;quot;&amp;amp;&amp;quot;).find(function(elem) { return elem.startsWith(&amp;quot;q=&amp;quot;); } );
  
  if (!q)
    alert(&amp;quot;queryStringにqがありません&amp;quot;);
  else {
    window.location.href = fore + &amp;quot;?&amp;quot; + q;
  }
} else
  alert(&amp;quot;google検索のページではなさそうです!&amp;quot;);&lt;/pre&gt;</content:encoded>
  </item>
  <item rdf:about="https://let.hatelabo.jp/den8/let/hJmdidqM7pAE">
    <link>https://let.hatelabo.jp/den8/let/hJmdidqM7pAE</link>
    <dc:date>2018-06-29T22:19:54Z</dc:date>
    <description>Hootlet without URL shortener</description>
    <dc:creator>den8</dc:creator>
    <title>[Let] Just Tweet With Hootsuite</title>
    <content:encoded>&lt;a href="javascript:var%20url%3D%27https%3A%2F%2Fhootsuite.com%2Fhootlet%2Fload%27%3B%28function%28%29%7Bif%28%21window.open%28url%2C%27t%27%2C%27scrollbars%3D0%2Ctoolbar%3D0%2Clocation%3D0%2Cresizable%3D0%2Cstatus%3D0%2Cwidth%3D450%2Cheight%3D600%27%29%29document.location.href%3Durl%7D%29%28%29%3Bvoid%200%3B"&gt;Just Tweet With Hootsuite&lt;/a&gt;&lt;pre&gt;/*
 * @title Just Tweet With Hootsuite
 * @description Hootlet without URL shortener
 * @include http*://*
 * @javascript_url
 */

// https://hootsuite.com/features/extensions/hootlet のbookmarkletを参考にした

var url = 'https://hootsuite.com/hootlet/load';

(function() {
  // この下の2行、本当に両方必要かは疑問。片方しか基本動かないんでは？
  if (!window.open(url,'t','scrollbars=0,toolbar=0,location=0,resizable=0,status=0,width=450,height=600'))
    document.location.href=url;
})();

void(0);&lt;/pre&gt;</content:encoded>
  </item>
  <item rdf:about="https://let.hatelabo.jp/den8/let/hLHVhryxldMv">
    <link>https://let.hatelabo.jp/den8/let/hLHVhryxldMv</link>
    <dc:date>2018-06-29T22:19:07Z</dc:date>
    <description>Hootlet without URL shortener</description>
    <dc:creator>den8</dc:creator>
    <title>[Let] Share With Hootsuite</title>
    <content:encoded>&lt;a href="javascript:var%20url%3D%27https%3A%2F%2Fhootsuite.com%2Fhootlet%2Fload%3Ftitle%3D%27%2BencodeURIComponent%28document.title%2B%22%20%22%2Bdocument.location.href%2B%22%20%22%29%3B%28function%28%29%7Bif%28%21window.open%28url%2C%27t%27%2C%27scrollbars%3D0%2Ctoolbar%3D0%2Clocation%3D0%2Cresizable%3D0%2Cstatus%3D0%2Cwidth%3D450%2Cheight%3D600%27%29%29document.location.href%3Durl%7D%29%28%29%3Bvoid%200%3B"&gt;Share With Hootsuite&lt;/a&gt;&lt;pre&gt;/*
 * @title Share With Hootsuite
 * @description Hootlet without URL shortener
 * @include http*://*
 * @javascript_url
 */

// https://hootsuite.com/features/extensions/hootlet のbookmarkletを参考にした

var url = 'https://hootsuite.com/hootlet/load?title=' + encodeURIComponent(document.title + &amp;quot; &amp;quot; + document.location.href + &amp;quot; &amp;quot;);

(function() {
  // この下の2行、本当に両方必要かは疑問。片方しか基本動かないんでは？
  if (!window.open(url,'t','scrollbars=0,toolbar=0,location=0,resizable=0,status=0,width=450,height=600'))
    document.location.href=url;
})();

void(0);&lt;/pre&gt;</content:encoded>
  </item>
  <item rdf:about="https://let.hatelabo.jp/den8/let/gYC-yIG60MuCXQ">
    <link>https://let.hatelabo.jp/den8/let/gYC-yIG60MuCXQ</link>
    <dc:date>2018-06-14T21:37:28Z</dc:date>
    <description>アマゾンのURLで商品名や参照元URLなど無用に長いURLを必要最低限まで短くしています。ただ、twitter用などに用意されているamzn.comやwww.の省略など、リダイレクトが発生するような短縮化は行っていません。</description>
    <dc:creator>den8</dc:creator>
    <title>[Let] アマゾンのURL短縮化(多ヶ国対応版)</title>
    <content:encoded>&lt;a href="javascript:if%28location.href.match%28%2F%28https%3A%5C%2F%5C%2Fwww%5C.amazon%5C.%28com%7Cco%5C.jp%7Cde%7Cfr%7Cco%5C.uk%7Ccn%29%29%2F%29%29%7Bvar%20e%3Ddocument.getElementById%28%22ASIN%22%29%3Bif%28e%21%3Dundefined%29%7Bvar%20shorten_url%3DRegExp.%241%2B%22%2Fdp%2F%22%2Be.value%3Bvar%20result%3Dprompt%28%22%E3%82%AF%E3%83%AA%E3%83%83%E3%83%97%E3%83%9C%E3%83%BC%E3%83%89%E3%81%ABURL%E3%82%92%E3%82%B3%E3%83%94%E3%83%BC%E3%81%97%E3%81%9F%E3%81%84%E5%A0%B4%E5%90%88Ctrl-C%E3%82%92%E6%8A%BC%E3%81%97%E3%81%A6%E3%81%8F%E3%81%A0%E3%81%95%E3%81%84%E3%80%82%5Cn%E7%9F%AD%E7%B8%AEURL%E3%81%AE%E3%83%9A%E3%83%BC%E3%82%B8%E3%81%B8%E7%A7%BB%E5%8B%95%E3%81%97%E3%81%9F%E3%81%84%E5%A0%B4%E5%90%88%E3%81%AFOK%E3%82%82%E3%81%97%E3%81%8F%E3%81%AFEnter%E3%82%92%E6%8A%BC%E3%81%97%E3%81%A6%E3%81%8F%E3%81%A0%E3%81%95%E3%81%84%E3%80%82%5Cn%E3%81%9D%E3%81%86%E3%81%A7%E3%81%AA%E3%81%84%E5%A0%B4%E5%90%88%E3%81%AF%E3%82%AD%E3%83%A3%E3%83%B3%E3%82%BB%E3%83%AB%E3%81%BE%E3%81%9F%E3%81%AFEscape%E3%81%A7%E3%83%80%E3%82%A4%E3%82%A2%E3%83%AD%E3%82%B0%E3%82%92%E9%96%89%E3%81%98%E3%81%A6%E3%81%8F%E3%81%A0%E3%81%95%E3%81%84%E3%80%82%22%2Cshorten_url%29%3Bif%28result%3D%3Dshorten_url%29location.href%3Dshorten_url%3Belse%20void%200%7Delse%20alert%28%22%E5%95%86%E5%93%81%E3%81%AE%E3%83%9A%E3%83%BC%E3%82%B8%E3%81%A7%E3%81%AF%E3%81%82%E3%82%8A%E3%81%BE%E3%81%9B%E3%82%93%28%E3%82%82%E3%81%97%E3%81%8F%E3%81%AF%E3%83%96%E3%83%83%E3%82%AF%E3%83%9E%E3%83%BC%E3%82%AF%E3%83%AC%E3%83%83%E3%83%88%E3%81%AE%E3%83%90%E3%82%B0%E3%81%A7%E5%AF%BE%E5%BF%9C%E3%81%A7%E3%81%8D%E3%81%AA%E3%81%84%E3%83%9A%E3%83%BC%E3%82%B8%E3%81%AA%E3%81%AE%E3%81%8B%E3%82%82%E3%81%97%E3%82%8C%E3%81%BE%E3%81%9B%E3%82%93%29%E3%80%82%22%29%7Delse%20alert%28%22%E5%AF%BE%E5%BF%9C%E3%82%B5%E3%82%A4%E3%83%88%E3%81%A7%E3%81%AF%E3%81%82%E3%82%8A%E3%81%BE%E3%81%9B%E3%82%93%E3%80%82%E3%81%93%E3%81%AE%E3%83%96%E3%83%83%E3%82%AF%E3%83%9E%E3%83%BC%E3%82%AF%E3%83%AC%E3%83%83%E3%83%88%E3%81%AFamazon.%28com%7Cco.jp%7Cde%7Cfr%7Cco.uk%7Ccn%29%E3%81%A7%E4%BD%BF%E3%81%88%E3%81%BE%E3%81%99%E3%80%82%22%29%3B"&gt;アマゾンのURL短縮化(多ヶ国対応版)&lt;/a&gt;&lt;pre&gt;/*
 * @title アマゾンのURL短縮化(多ヶ国対応版)
 * @description アマゾンのURLで商品名や参照元URLなど無用に長いURLを必要最低限まで短くしています。ただ、twitter用などに用意されているamzn.comやwww.の省略など、リダイレクトが発生するような短縮化は行っていません。
 * @include https://www.amazon.*
 * @license 悪さしなければ自由に使ってもらって構いません
 * @javascript_url
 */

if (location.href.match(/(https:\/\/www\.amazon\.(com|co\.jp|de|fr|co\.uk|cn))/)) {
    var e = document.getElementById(&amp;quot;ASIN&amp;quot;);
    if (e != undefined) {
        var shorten_url = RegExp.$1 + &amp;quot;/dp/&amp;quot; + e.value;
        var result = prompt(&amp;quot;クリップボードにURLをコピーしたい場合Ctrl-Cを押してください。\n短縮URLのページへ移動したい場合はOKもしくはEnterを押してください。\nそうでない場合はキャンセルまたはEscapeでダイアログを閉じてください。&amp;quot;, shorten_url);
        if (result == shorten_url) location.href = shorten_url;
        else void(0);
    } else alert(&amp;quot;商品のページではありません(もしくはブックマークレットのバグで対応できないページなのかもしれません)。&amp;quot;);
} else alert(&amp;quot;対応サイトではありません。このブックマークレットはamazon.(com|co.jp|de|fr|co.uk|cn)で使えます。&amp;quot;);&lt;/pre&gt;</content:encoded>
  </item>
  <item rdf:about="https://let.hatelabo.jp/den8/let/hLHWlbSBnrIH">
    <link>https://let.hatelabo.jp/den8/let/hLHWlbSBnrIH</link>
    <dc:date>2014-09-25T05:21:11Z</dc:date>
    <description>my bookmarklet</description>
    <dc:creator>den8</dc:creator>
    <title>[Let] Jenkinsのパンくずリストを削除するスクリプト</title>
    <content:encoded>&lt;a href="javascript:%22https%3A%2F%2Flet.st-hatelabo.com%2Fden8%2Flet%2FhLHWlbSBnrIH.bookmarklet.js%20%28arg%29%22.replace%28%2F%28%5CS%2B%29%5Cs%2B%28%5CS%2A%29%2F%2Cfunction%28s%2Curl%2Carg%29%7Bs%3Ddocument.createElement%28%22script%22%29%3Bs.charset%3D%22utf-8%22%3Bs.src%3Durl%2B%22%3Fs%3D%22%2BencodeURIComponent%28arg%29%3Bdocument.body.appendChild%28s%29%7D%29%3Bvoid%280%29%3B"&gt;Jenkinsのパンくずリストを削除するスクリプト&lt;/a&gt;&lt;pre&gt;/*
 * @title Jenkinsのパンくずリストを削除するスクリプト
 * @description my bookmarklet
 * @include http://*
 * @license MIT License
 * @require 
 */


javascript: (function() {
    var dom_obj = document.getElementById(&amp;quot;top-nav&amp;quot;);
    var dom_obj_parent = dom_obj.parentNode;

    dom_obj_parent.removeChild(dom_obj);
}());&lt;/pre&gt;</content:encoded>
  </item>
</rdf:RDF>
