<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:media="http://search.yahoo.com/mrss/">
<channel>
<title>ClipboardFusion RSS: Macro: Shorten YouTube video link</title>
<atom:link href="https://www.clipboardfusion.com/Discussions/RSS/?TopicID=d177dc8e-7e80-4d38-8c5d-f18a69b0ae08" rel="self" type="application/rss+xml" />
<link>https://www.clipboardfusion.com/Discussions/RSS/?TopicID=d177dc8e-7e80-4d38-8c5d-f18a69b0ae08</link>
<description>ClipboardFusion RSS: Macro: Shorten YouTube video link</description>
<lastBuildDate>Tue, 27 Oct 2026 05:41:32 GMT</lastBuildDate>
<language>en</language>
<sy:updatePeriod>hourly</sy:updatePeriod>
<sy:updateFrequency>1</sy:updateFrequency>
<generator>https://www.clipboardfusion.com/Discussions/RSS/?TopicID=d177dc8e-7e80-4d38-8c5d-f18a69b0ae08</generator>
<item>
<title>RE: Macro: Shorten YouTube video link</title>
<link>https://www.clipboardfusion.com/Discussions/View/macro-shorten-youtube-video-link/?ID=d177dc8e-7e80-4d38-8c5d-f18a69b0ae08#2</link>
<pubDate>Wed, 04 Jan 2017 14:07:17 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/macro-shorten-youtube-video-link/?ID=d177dc8e-7e80-4d38-8c5d-f18a69b0ae08#2</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Thanks for sharing that! I've posted it to the online repository as well, which is accessible via the "Download Pre-Made Macros" button in the ClipboardFusion settings]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Thanks for sharing that! I've posted it to the online repository as well, which is accessible via the "Download Pre-Made Macros" button in the ClipboardFusion settings <img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/face-smile.light.svg" alt=":)" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:16px;height:16px;" HelpButtonData=":)" />
</div>
]]></content:encoded>
</item>
<item>
<title>Macro: Shorten YouTube video link</title>
<link>https://www.clipboardfusion.com/Discussions/View/macro-shorten-youtube-video-link/?ID=d177dc8e-7e80-4d38-8c5d-f18a69b0ae08</link>
<pubDate>Fri, 30 Dec 2016 16:57:44 GMT</pubDate>
<dc:creator>Binary Fortress Software</dc:creator>
<guid isPermaLink="false">https://www.clipboardfusion.com/Discussions/View/macro-shorten-youtube-video-link/?ID=d177dc8e-7e80-4d38-8c5d-f18a69b0ae08</guid>
<category>ClipboardFusion</category>
<description><![CDATA[Here's a quick macro to shorten a YouTube video from the full https://www.youtube.com/watch?v=&lt;id&gt; to the shortened youtu.be version.
I've attached the .cfmacro file below for easy importing into ClipboardFusion, or here's the source.
Code
Copy
Select All
using System;&#xA;using System...]]></description>
<content:encoded><![CDATA[<div class="CTDiscussions">
Here's a quick macro to shorten a YouTube video from the full https://www.youtube.com/watch?v=&lt;id&gt; to the shortened youtu.be version.<br/>
<br/>
I've attached the .cfmacro file below for easy importing into ClipboardFusion, or here's the source.<br/>
<br/>
<div class="col-md-12 BoxWrap"><div class="Box table-responsive"><a name="code" style="width:0; height:0;"></a><h2 class="TableTitle" style="border:0"><div class="TableTitleText">Code</div><div class="TitleButtons"><div class="TableTitleButton"><a href="#" onclick="return false;" data-clipboard-target="#code01a17be0cc6d71deb99f172c34e95ab8" class="ClipboardCopyControl"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/clone.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Copy</span></a></div><div class="TableTitleButton"><a href="#" onclick="bfs.util.codeEditorSelectAll('code01a17be0cc6d71deb99f172c34e95ab8Js'); return false;"><img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/square-check.blue.svg" style="box-sizing:border-box;position:relative;overflow:hidden;width:auto;max-width:16px;height:16px;" /><span class="Text">Select All</span></a></div></div></h2><div class="TableTitleContent table-responsive"><div class="AceEditorWrapper" style="border-top:solid 1px var(--color-default-border);padding:0"><pre id="code01a17be0cc6d71deb99f172c34e95ab8Js" name="code01a17be0cc6d71deb99f172c34e95ab8Js" contenteditable="true" spellcheck="true" class="skiptranslate" style="width:100%;min-height:75px">using System;&#xA;using System.Text.RegularExpressions;&#xA;&#xA;public static class ClipboardFusionHelper&#xA;{&#xA;    public static string ProcessText(string text)&#xA;    {&#xA;        Regex youtubeRegex = new Regex(@&quot;https://www\.youtube\.com\/watch\?v\=(?&amp;lt;id&amp;gt;[^\&amp;]*)(?:\&amp;.*)?&quot;);&#xA;        Match match = youtubeRegex.Match(text);&#xA;&#xA;        if (!match.Success) {&#xA;            // If this isn&#x27;t a YouTube video, don&#x27;t do anything to it&#xA;            return text;&#xA;        }&#xA;&#xA;        Group idGroup = match.Groups[&quot;id&quot;];&#xA;        string idText = idGroup.Value;&#xA;        return &quot;https://youtu.be/&quot; &#x2B; idText;&#xA;    }&#xA;}</pre><textarea id="code01a17be0cc6d71deb99f172c34e95ab8" name="code01a17be0cc6d71deb99f172c34e95ab8" style="position:absolute;top:0;left:-999999px;width:1px;height:1px"></textarea></div>
</div></div></div><br/>
<br/>
If there's a better place to submit this, please let me know and I can re-submit. <img src="https://www.clipboardfusion.com/MediaCommon/SVGs/FontAwesome/face-smile.light.svg" alt=":)" style="box-sizing:border-box;position:relative;overflow:hidden;vertical-align:middle !important;width:16px;height:16px;" HelpButtonData=":)" /><br/>
<br/>
Hopefully someone can find this useful!
</div>
]]></content:encoded>
</item>
</channel>
</rss>