I'd like to define an alias that runs the following two commands consecutively.
gnome-screensaver
gnome-screensaver-command --lock
Right now I've added
alias lock='gnome-screensaver-command --lock'
to my .bashrc but since I lock my workstation so often it would be easier to just type one command.
...
What is the correct way to pick up the list of "pages" via a class that inherits from System.Configuration.Section if I used a app.config like this?
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="XrbSettings" type="Xrb.UI.XrbSettings,Xrb.UI" />
</configSections>
<XrbSettings>
<pag...
I'm working on a large C++ system built with ant+cpptasks. It works well enough, but the build.xml file is getting out of hand, due to standard operating procedure for adding a new library or executable target being to copy-and-paste another lib/exe's rules (which are already quite large). If this was "proper code", it'd be screaming o...
I am setting up a web server for a client. They will be using a web app (PHP/LAMP) that I am building. The server will be sitting within their network locally. There will also be a MySQL database on the same server. The load on the server will only be 20-25 concurrent users, but uptime and performance is still very important.
The app...
I have a EAR with structures like:
APP.ear
- APP1.war
- WEB-INF/classes/log4j.properties
- APP2.war
- WEB-INF/classes/log4j.properties
- app1-ejb.jar
- app2-ejb.jar
- log4j.jar
- spring.jar
- commons-lang.jar (...and other jar)
I want each WAR to have their own application log. But it seems the above configuration does not wo...
I run a webserver on debian lenny. How to setup postfix to send emails to users for user registration, forgot password? How to configure the system?
I don't want the system to receive any emails from outside world, including user reply.
...
hi all,
hope someone can help with something that is really budding me.
i have a smart client, a couple of web services and some DLL's.
the dll's are essentially forms and controls. the dll's reference the web services within themselves.
the problem i have is how to change the references to the web services IN THE DLL's dynamically as ...
Conkeror has changed the way I browse the web: it's basically Emacs + Firefox with javascript based configuration in .conkerrorc rather than elisp configuration in .emacs.
I've built up a huge library of .emacs customizations over the years by getting little bits and pieces from others. I'm just starting with Conkeror but the fact that...
(Asked by @tomhollander on Twitter)
What's the most appropriate exception to throw if a required app/web.config configuration setting is not present?
...
I have a complex application with many pages.
Each page can have many possible routes to other pages: 'A' can go to 'B' or 'C', 'B' can go to 'A' but not 'C'. etc.
Rather than embed this "where to go to next" logic in each page (horror!) I of course want to encapsulate it in a main point of control. 'A' doesn't need to know about 'B' ...
My client/server application is using WCF for communication, which has been great. However one shortcoming of the current architecture is that I must use known type configuration for certain transmitted types. I'm using an in-house Pub/Sub mechanism and this requirement is unavoidable.
The problem is that it's easy to forget to add th...
I am wondering what would be considered best practice when setting up reusable components / libraries in .net. I have a webservice that utilizes a library that contains a few database connection for interacting with databases. I am wondering how I should set my library up when it comes to specifying the connection strings.
I need to be...
I am trying to override the ApplyConfiguration method in my custom ServiceHost to read the configuration from a database instead of app.config. Ideally I would want to be able to do something like this:
Configuration config = GetConfigFromMyDatabase(...);
ServiceModelSectionGroup serviceModel = ServiceModelSectionGroup.GetSectionGroup(...
Can we configure MySQL 4 with XAMPP? The latest version of XAMPP comes with MySQL5
...
I know how to create custom configuration handlers for my .NET application. There are plenty of posts on StackOverflow that cover what needs to be done. I've spent most of the day knocking out classes that derive from ConfigurationElement.
I'm getting worried that this approach involves a lot of work - more work than I was expecting. I'...
In a regular ASP.NET application, you might have a customErrors section like the following:
<customErrors mode="On">
<error statusCode="404" redirect="Nice-FileNotFound-Page.aspx"/>
</customErrors>
Is it possible to set the 404 error programmatically at Application_Start? Something like the following:
// Figure out which page shou...
I have a rather large spring application, and all I'm trying to share is a single Map (using util.ConcurrentMap as implementation).
To do this, I created a bean in my appContext, and I tried to use the following tc-config line:
*/applicationContext.xml
Must I do something else to enable this to work? MyClass is a rather s...
I am trying to add
<location inheritInChildApplications="false">
to my parent web application's web.config but it doesn't seem to be working.
My parent's web.config has:
<configuration>
<configSections>
</configSections>
// 10 or so custom config sections like log4net, hibernate,
<connectionStrings>
</connectio...
I have a php script that does some processing (creates remittance advice PDFs, self-billing invoices, Sage CSV file etc...) and at the end outputs a screen with a form, in which the names and e-mail addresses of the people paid appear. User makes a selection of names by clicking check boxes and then there is a Send button which sends out...
If I am to have connectionstrings read from a config file in my application and I need to be able to change the connectionstrings as the application is moved from dev to uat to prod should I be using settings files at all as there the connection strings are compiled into the assembly which I will be moving from environment to environment...