AskOverflow.Dev

AskOverflow.Dev Logo AskOverflow.Dev Logo

AskOverflow.Dev Navigation

  • 主页
  • 系统&网络
  • Ubuntu
  • Unix
  • DBA
  • Computer
  • Coding
  • LangChain

Mobile menu

Close
  • 主页
  • 系统&网络
    • 最新
    • 热门
    • 标签
  • Ubuntu
    • 最新
    • 热门
    • 标签
  • Unix
    • 最新
    • 标签
  • DBA
    • 最新
    • 标签
  • Computer
    • 最新
    • 标签
  • Coding
    • 最新
    • 标签
主页 / user-4236

begtognen's questions

Martin Hope
begtognen
Asked: 2011-05-05 03:53:58 +0800 CST

我可以使用键盘快捷键来实现文本宏吗?

  • 3

我知道 Autokey 具有创建文本宏的功能,但我发现它非常有问题,并且没有新版本发布。(IronAHK 看起来是一个很好的选择,但它实际上还没有可用。)

所以我想自己做以下事情:将 control-L 映射到这个(是的,只需输入一堆破折号 - 我开始很简单) -

“---------------”

我可以通过键盘快捷键做到这一点吗?.sh 脚本效果最好吗?如果是这样,你能指出我学习如何创建那种 .sh 脚本的正确方向吗?

如果这是一个愚蠢的解决方案,是否有替代程序可以让我映射文本宏?

非常感谢。

keyboard
  • 1 个回答
  • 2858 Views
Martin Hope
begtognen
Asked: 2011-04-12 04:32:24 +0800 CST

最新更新后无法识别外接声卡

  • 0

我正在运行 Ubuntu 10.04。

直到昨天,我的 Audiophile 声卡都运行良好。我运行了最新的更新,现在它没有显示在声音首选项下。(当我插入 USB 耳机时,它出现在声音首选项下并且工作正常。)

声卡列在 aplay -l 下。

**** 播放硬件设备列表 ****
卡0:Audiophile192 [M Audio Audiophile192],设备0:ICE1724 [ICE1724]
  子设备:1/1
  子设备#0:子设备#0
卡 0:Audiophile192 [M Audio Audiophile192],设备 1:ICE1724 IEC958 [ICE1724 IEC958]
  子设备:1/1
  子设备#0:子设备#0
卡 1:Intel [HDA Intel],设备 0:ALC888 模拟 [ALC888 模拟]
  子设备:1/1
  子设备#0:子设备#0
卡 2:HDMI [HDA ATI HDMI],设备 3:ATI HDMI [ATI HDMI]
  子设备:1/1
  子设备#0:子设备#0

声卡列在 lspci | grep -i audio, as Envy24(我不知道为什么这里叫 Envy24 而不是 Audiophile,但一直都是这样。)

00:1b.0 音频设备:英特尔公司 82801I(ICH9 系列)高清音频控制器(rev 02)
01:00.1 音频设备:ATI Technologies Inc RV710/730
02:00.0 多媒体音频控制器:VIA Technologies Inc. VT1720/24 [Envy24PT/HT] PCI 多通道音频控制器(rev 01)

这是Alsa信息:查看

声卡列表如下:

!! ALSA 认可的声卡
!!-----------------------------

0 [发烧友192]:ICE1724 - M 音响发烧友192   
                     M Audio Audiophile192 at 0xdf00, irq 2

如果我从终端运行 Alsamixer,正确的 Audiophile 声卡就是显示的那个。

我不确定下一步该怎么做。非常感谢您的任何帮助/建议。

sound
  • 1 个回答
  • 1268 Views
Martin Hope
begtognen
Asked: 2011-03-08 06:09:30 +0800 CST

Youtube 完全崩溃了计算机

  • 1

大约一周前,Synaptic 定期更新在后台运行。从那以后,当我尝试观看 Youtube 视频(只是在视频上点击“播放”)时,显示器会暂时变黑,然后只是随机闪烁的颜色条。修复它的唯一方法是使用电源按钮关闭计算机,然后重新启动计算机。我正在使用 Ubuntu 10.04。自从那次更新以来,看起来很多人都遇到了麻烦(红色视频,根本不起作用的视频),但我还没有发现任何人遇到这种壮观的崩溃。我已经尝试过 Firefox 和 Chromium,结果相同。有任何想法吗?

youtube
  • 2 个回答
  • 2873 Views
Martin Hope
begtognen
Asked: 2011-01-29 10:24:12 +0800 CST

通过脚本调整 Conky 布局

  • 1

我在 Conky 中使用了一个脚本,以便在我的桌面上显示我的新 gmail。

它工作得很好,但有点难看,我不知道如何解决它。

我目前得到的看起来像这样:

在此处输入图像描述

我想要的是这样的:

在此处输入图像描述

任何关于如何实现这一点的想法都非常感谢。这是我目前正在使用的完整脚本。

#!/usr/bin/perl

use Switch;
use Text::Wrap;

my $what=$ARGV[0];

$user="username"; #username for gmail account
$pass="password"; #password for gmail account
$file="/tmp/gmail.html"; #temporary file to store gmail

#wrap format for subject
$Text::Wrap::columns=65; #Number of columns to wrap subject at
$initial_tab=""; #Tab for first line of subject
$subsequent_tab="\t"; #tab for wrapped lines
$quote="\""; #put quotes around subject

#limit the number of emails to be displayed
$emails=-1; #if -1 display all emails

&passwd; #give password the proper url character encoding

switch($what){ #determine what the user wants
    case "n" {&gmail; print "$new\n";} #print number of new emails
    case "s" { #print $from and $subj for new email
        &gmail;
        if ($new>0){
            my $size=@from;
            if ($emails!=-1 && $size>$emails){$size=$emails;} #limit number of emails displayed
            for(my $i=0; $i$emails){print "$emails out of $size new emails displayed\n";}
        }
    }   
    case "e" { #print number of new emails, $from, and $subj
        &gmail;
        if($new==0){print "You have no new emails.\n";}
        else{
            print "You have $new new email(s).\n";
            my $size=@from;
            if ($emails!=-1 && $size>$emails){$size=$emails;} #limit number of emails displayed
            for(my $i=0; $i$emails){print "$emails out of $size new emails displayed\n";}
        }
    }
    else {
        print "Usage Error: gmail.pl \n";
        print "\tn displays number of new emails\n";
        print "\ts displays from line and subject line for each new email.\n";
        print "\te displays the number of new emails and from line plus \n";
        print "\t\tsubject line for each new email.\n";
    } #didn't give proper option
}

sub gmail{
    if(!(-e $file)){ #create file if it does not exists
        `touch $file`;
    } 

    #get new emails
    `wget -O - https://$user:$pass\@mail.google.com/mail/feed/atom --no-check-certificate> $file`;

    open(IN, $file); #open $file

    my $i=0; #initialize count
    $new=0; #initialize new emails to 0

    my $flag=0;

    while(){ #cycle through $file
        if(//){$flag=1;}
        elsif(/(\d+)/){$new=$1;} #grab number of new emails
        elsif($flag==1){ 
            if(/.+/){push(@subj, &msg);} #grab new email titles
            elsif(/(.+)/){push(@from, $1); $flag=0;} #grab new email from lines
        }
    }

    close(IN); #close $file
}

sub passwd{ #change to url escape codes in password
    #URL ESCAPE CODES
    $_=$pass;
    s/\%/\%25/g;
    s/\#/\%23/g;
    s/\$/\%24/g;
    s/\&/\%26/g;
    s/\//\%2F/g;
    s/\:/\%3A/g;
    s/\;/\%3B/g;
    s/\/\%3E/g;
    s/\?/\%3F/g;
    s/\@/\%40/g;
    s/\[/\%5B/g;
    s/\\/\%5C/g;
    s/\]/\%5D/g;
    s/\^/\%5E/g;
    s/\`/\%60/g;
    s/\{/\%7B/g;
    s/\|/\%7C/g;
    s/\}/\%7D/g;
    s/\~/\%7E/g;
    $pass=$_;
}

sub msg{
    #THE HTML CODED CHARACTER SET [ISO-8859-1]
    chomp; s/(.+)/$1/; #get just the subject
    #now replace any special characters
    s/\&\#33\;/!/g;        #Exclamation mark
    s/\&\#34\;/"/g; s/\"\;/"/g;      #Quotation mark
    s/\&\#35\;/#/g;        #Number sign
    s/\&\#36\;/\$/g;        #Dollar sign
    s/\&\#37\;/%/g;        #Percent sign
    s/\&\#38\;/&/g; s/\&\;/&/g;        #Ampersand
    s/\&\#39\;/'/g;        #Apostrophe
    s/\&\#40\;/(/g;        #Left parenthesis
    s/\&\#41\;/)/g;        #Right parenthesis
    s/\&\#42\;/*/g;        #Asterisk
    s/\&\#43\;/+/g;        #Plus sign
    s/\&\#44\;/,/g;        #Comma
    s/\&\#45\;/-/g;        #Hyphen
    s/\&\#46\;/./g;        #Period (fullstop)
    s/\&\#47\;/\//g;        #Solidus (slash)
    s/\&\#58\;/:/g;        #Colon
    s/\&\#59\;/\;/g;        #Semi-colon
    s/\&\#60\;//g; s/\>\;/>/g;        #Greater than
    s/\&\#63\;/\?/g;        #Question mark
    s/\&\#64\;/\@/g;        #Commercial at
    s/\&\#91\;/\[/g;        #Left square bracket
    s/\&\#92\;/\\/g;        #Reverse solidus (backslash)
    s/\&\#93\;/\]/g;        #Right square bracket
    s/\&\#94\;/\^/g;        #Caret
    s/\&\#95\;/_/g;        #Horizontal bar (underscore)
    s/\&\#96\;/\`/g;        #Acute accent
    s/\&\#123\;/\{/g;        #Left curly brace
    s/\&\#124\;/|/g;        #Vertical bar
    s/\&\#125\;/\}/g;        #Right curly brace
    s/\&\#126\;/~/g;        #Tilde
    s/\&\#161\;/¡/g;        #Inverted exclamation
    s/\&\#162\;/¢/g;        #Cent sign
    s/\&\#163\;/£/g;        #Pound sterling
    s/\&\#164\;/¤/g;        #General currency sign
    s/\&\#165\;/¥/g;        #Yen sign
    s/\&\#166\;/¦/g;        #Broken vertical bar
    s/\&\#167\;/§/g;        #Section sign
    s/\&\#168\;/¨/g;        #Umlaut (dieresis)
    s/\&\#169\;/©/g; s/\©\;/©/g;        #Copyright
    s/\&\#170\;/ª/g;        #Feminine ordinal
    s/\&\#171\;/«/g;        #Left angle quote, guillemotleft
    s/\&\#172\;/¬/g;        #Not sign
    s/\&\#174\;/®/g;        #Registered trademark
    s/\&\#175\;/¯/g;        #Macron accent
    s/\&\#176\;/°/g;        #Degree sign
    s/\&\#177\;/±/g;        #Plus or minus
    s/\&\#178\;/²/g;        #Superscript two
    s/\&\#179\;/³/g;        #Superscript three
    s/\&\#180\;/´/g;        #Acute accent
    s/\&\#181\;/µ/g;        #Micro sign
    s/\&\#182\;/¶/g;        #Paragraph sign
    s/\&\#183\;/·/g;        #Middle dot
    s/\&\#184\;/¸/g;        #Cedilla
    s/\&\#185\;/¹/g;        #Superscript one
    s/\&\#186\;/º/g;        #Masculine ordinal
    s/\&\#187\;/»/g;        #Right angle quote, guillemotright
    s/\&\#188\;/¼/g; s/\¼\;/¼/g;       # Fraction one-fourth
    s/\&\#189\;/½/g; s/\½\;/½/g;       # Fraction one-half
    s/\&\#190\;/¾/g; s/\¾\;/¾/g;       # Fraction three-fourths
    s/\&\#191\;/¿/g;        #Inverted question mark
    s/\&\#192\;/À/g;        #Capital A, grave accent
    s/\&\#193\;/Á/g;        #Capital A, acute accent
    s/\&\#194\;/Â/g;        #Capital A, circumflex accent
    s/\&\#195\;/Ã/g;        #Capital A, tilde
    s/\&\#196\;/Ä/g;        #Capital A, dieresis or umlaut mark
    s/\&\#197\;/Å/g;        #Capital A, ring
    s/\&\#198\;/Æ/g;        #Capital AE dipthong (ligature)
    s/\&\#199\;/Ç/g;        #Capital C, cedilla
    s/\&\#200\;/È/g;        #Capital E, grave accent
    s/\&\#201\;/É/g;        #Capital E, acute accent
    s/\&\#202\;/Ê/g;        #Capital E, circumflex accent
    s/\&\#203\;/Ë/g;        #Capital E, dieresis or umlaut mark
    s/\&\#204\;/Ì/g;        #Capital I, grave accent
    s/\&\#205\;/Í/g;        #Capital I, acute accent
    s/\&\#206\;/Î/g;        #Capital I, circumflex accent
    s/\&\#207\;/Ï/g;        #Capital I, dieresis or umlaut mark   
    s/\&\#208\;/Ð/g;        #Capital Eth, Icelandic
    s/\&\#209\;/Ñ/g;        #Capital N, tilde
    s/\&\#210\;/Ò/g;        #Capital O, grave accent
    s/\&\#211\;/Ó/g;        #Capital O, acute accent
    s/\&\#212\;/Ô/g;        #Capital O, circumflex accent
    s/\&\#213\;/Õ/g;        #Capital O, tilde
    s/\&\#214\;/Ö/g;        #Capital O, dieresis or umlaut mark
    s/\&\#215\;/×/g;        #Multiply sign
    s/\&\#216\;/Ø/g;        #Capital O, slash
    s/\&\#217\;/Ù/g;        #Capital U, grave accent
    s/\&\#218\;/Ú/g;        #Capital U, acute accent
    s/\&\#219\;/Û/g;        #Capital U, circumflex accent
    s/\&\#220\;/Ü/g;        #Capital U, dieresis or umlaut mark
    s/\&\#221\;/Ý/g;        #Capital Y, acute accent
    s/\&\#222\;/Þ/g;        #Capital THORN, Icelandic
    s/\&\#223\;/ß/g;        #Small sharp s, German (sz ligature)
    s/\&\#224\;/à/g;        #Small a, grave accent
    s/\&\#225\;/á/g;        #Small a, acute accent
    s/\&\#226\;/â/g;        #Small a, circumflex accent
    s/\&\#227\;/ã/g;        #Small a, tilde
    s/\&\#228\;/ä/g;        #Small a, dieresis or umlaut mark
    s/\&\#229\;/å/g;        #Small a, ring
    s/\&\#230\;/æ/g;        #Small ae dipthong (ligature)
    s/\&\#231\;/ç/g;        #Small c, cedilla
    s/\&\#232\;/è/g;        #Small e, grave accent
    s/\&\#233\;/é/g;        #Small e, acute accent
    s/\&\#234\;/ê/g;        #Small e, circumflex accent
    s/\&\#235\;/ë/g;        #Small e, dieresis or umlaut mark
    s/\&\#236\;/ì/g;        #Small i, grave accent
    s/\&\#237\;/í/g;        #Small i, acute accent
    s/\&\#238\;/î/g;        #Small i, circumflex accent
    s/\&\#239\;/ï/g;        #Small i, dieresis or umlaut mark
    s/\&\#240\;/ð/g;        #Small eth, Icelandic
    s/\&\#241\;/ñ/g;        #Small n, tilde
    s/\&\#242\;/ò/g;        #Small o, grave accent
    s/\&\#243\;/ó/g;        #Small o, acute accent
    s/\&\#244\;/ô/g;        #Small o, circumflex accent
    s/\&\#245\;/õ/g;        #Small o, tilde
    s/\&\#246\;/ö/g;        #Small o, dieresis or umlaut mark
    s/\&\#247\;/÷/g;        #Division sign
    s/\&\#248\;/ø/g;        #Small o, slash
    s/\&\#249\;/ù/g;        #Small u, grave accent
    s/\&\#250\;/ú/g;        #Small u, acute accent
    s/\&\#251\;/û/g;        #Small u, circumflex accent
    s/\&\#252\;/ü/g;        #Small u, dieresis or umlaut mark
    s/\&\#253\;/ý/g;        #Small y, acute accent
    s/\&\#254\;/þ/g;        #Small thorn, Icelandic
    s/\&\#255\;/ÿ/g;        #Small y, dieresis or umlaut mark
    s/^\s+//;
    return $_;
}

在进行 Ward 的更改后: 在此处输入图像描述

conky
  • 1 个回答
  • 1670 Views
Martin Hope
begtognen
Asked: 2011-01-03 05:29:16 +0800 CST

可以自动显示正确的星期几吗?

  • 3

我想调整一下我的 Conky,让它自动正确显示星期几。例如,如果今天是星期二,它看起来像这样:

周二

周三

周四

星期五

[ETC。]

然后明天,自动,它看起来像这样:

周三

周四

星期五

[ETC。]

我知道我可以让它显示今天的日期,如下所示:

${时间 %A}

但是如何让它显示明天的日期呢?

非常感谢您的任何帮助/建议。

conky
  • 1 个回答
  • 1703 Views
Martin Hope
begtognen
Asked: 2010-12-03 04:51:07 +0800 CST

如何安装 Audacity 的第二个版本?

  • 4

我正在运行最新版本的 Audacity,1.3.12。

我想安装第二个版本(1.2.6),因为我想访问一个只存在于该版本中的过滤器。(因为我只是出于这个原因安装它,所以我的 1.3.12 安装需要保持不变。)

作为最近从 Windows XP 转换过来的人,我对 Ubuntu 如何处理安装文件仍然有些模糊。我可以只使用此页面中的 deb 文件吗?

还是会破坏我当前的 1.3.12 安装?

software-installation
  • 3 个回答
  • 777 Views
Martin Hope
begtognen
Asked: 2010-11-11 09:22:14 +0800 CST

Snippits:尝试运行 ks do 时出错

  • 1

我很想使用 Snippits,但在我仔细遵循这些指示之后:

http://lifehacker.com/351285/automate-repetitive-typing-with-snippits

我尝试使用分配给 Snippits 的键盘快捷键并得到错误:

“尝试运行时出错(ks do)”

我环顾四周,这似乎是一个常见问题,但我没有找到答案。任何想法将不胜感激。

shortcut-keys
  • 1 个回答
  • 200 Views
Martin Hope
begtognen
Asked: 2010-11-01 03:25:30 +0800 CST

Thunderbird 不会记得我关闭了全局搜索和索引

  • 3

我一遍又一遍地关闭了 Thunderbird 的“全局搜索和索引”。我已经多次删除了 global-messages-db.sqlite 文件。

这适用于一个会话,但是一旦我重新启动计算机,Thunderbird 就会重新使用全局搜索和索引。(虽然看起来它没有在首选项下使用。)

有什么想法可以让 Thunderbird 记住吗?非常感谢。

thunderbird search preferences indexing
  • 1 个回答
  • 750 Views
Martin Hope
begtognen
Asked: 2010-10-18 04:09:28 +0800 CST

将 shift+tab 分配给右侧的控制按钮?

  • 6

是否可以将Shift+分配Tab给右侧的控制键?

shortcut-keys
  • 1 个回答
  • 1247 Views

Sidebar

Stats

  • 问题 205573
  • 回答 270741
  • 最佳答案 135370
  • 用户 68524
  • 热门
  • 回答
  • Marko Smith

    如何运行 .sh 脚本?

    • 16 个回答
  • Marko Smith

    如何安装 .tar.gz(或 .tar.bz2)文件?

    • 14 个回答
  • Marko Smith

    如何列出所有已安装的软件包

    • 24 个回答
  • Marko Smith

    无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗?

    • 25 个回答
  • Martin Hope
    Flimm 如何在没有 sudo 的情况下使用 docker? 2014-06-07 00:17:43 +0800 CST
  • Martin Hope
    Ivan 如何列出所有已安装的软件包 2010-12-17 18:08:49 +0800 CST
  • Martin Hope
    La Ode Adam Saputra 无法锁定管理目录 (/var/lib/dpkg/) 是另一个进程在使用它吗? 2010-11-30 18:12:48 +0800 CST
  • Martin Hope
    David Barry 如何从命令行确定目录(文件夹)的总大小? 2010-08-06 10:20:23 +0800 CST
  • Martin Hope
    jfoucher “以下软件包已被保留:”为什么以及如何解决? 2010-08-01 13:59:22 +0800 CST
  • Martin Hope
    David Ashford 如何删除 PPA? 2010-07-30 01:09:42 +0800 CST

热门标签

10.10 10.04 gnome networking server command-line package-management software-recommendation sound xorg

Explore

  • 主页
  • 问题
    • 最新
    • 热门
  • 标签
  • 帮助

Footer

AskOverflow.Dev

关于我们

  • 关于我们
  • 联系我们

Legal Stuff

  • Privacy Policy

Language

  • Pt
  • Server
  • Unix

© 2023 AskOverflow.DEV All Rights Reserve