Show build configuration in Xcode - xcode

I have a project (C++ project within XCode 5) with multiple build configurations that I regularly switch between. Currently, to see the active configuration I have to click on the scheme and select 'Edit Scheme...' to view/change the configuration. It'd be nice to put this information somewhere more visible, or access it with a hotkey. Is this possible?

You can use Command+Shift+< to open the "Edit Scheme...". You can change the hotkey in XCode->Preference->KeyBindings->Menu->Product Menu->Scheme-EditScheme

Another option that I like is to create multiple schemes. Manage schemes and select your production scheme. Click the + button to add another scheme and name it with a -Dev postfix. Select the appropriate configuration.
Now you'll have multiple schemes that can be selected from the popup-menu easily for running and archiving.
Also by using this method, stored binaries in the Archive are tagged with the scheme name which can be useful.

Related

Adding localizable strings on xcode 10.1

I have a swift app where I now want to add translations for some of the strings used in the app using NSLocalizedString.
In order to do this, I added a file named Localizable.strings to the project and pressed the "localize" button in the file inspector in order to add multiple languages to it. However only english appeared in the localization list, and I seem to be unable to add more.
Having looked around at SO and just googling around, many of the articles on how to do this mention that I should add more languages to my project under build settings. But the only setting I can change under Localization is one named "Localized String Macro Names", and there is no option to add languages there. There is also no "Use Base Internationalization" marker to check.
I have also tried to click on my project, then Editor -> Add Localization, but there all the languages are greyed out and I am unable to chose any of them.
I therefore suppose that you are supposed to do this differently in the latest version of xcode (10.1 atm). Can anyone help me figure out how you are supposed to do it?
It's about the project settings. Take a look at the image:
Under the Localizations you add new languages. After you add the language here you select which files you want to localize.
// update
Click on the top right button shown in the screen below and select your project under the PROJECT tab.
You just selected the wrong settings. The picture that you attached is actually under TARGET settings -> Build Settings, rather than project settings.
See the picture below to select "project settings" under xcode 10:
Xcode 10, project settings

Where Xcode 8 places build logs?

So, the question describes itself.
I want to edit the log after each build to cut out swift 3 ugly warnings like Result of call to '...' is unused
In Xcode > Preferences > Locations you can define (or automatically accept the default path ~/Library/Developer/Xcode/DerivedData/) the location of the 'DerivedData' folder which is where the build logs are stored.
Go there and tap the -> arrow to see the folder organization. Apple introduces unique folder name extensions which would have to be determined and built into any script that would analyze or process the log.
You could always go to your target settings and set the "Inhibit All Warnings" checkbox to ON.
As for editing the transcript directly, I suspect this is something you can't easily do, as build transcripts can be exported (hold down the control key while clicking on a build log in the Report Navigator in the left side of the Xcode project window) and I think they must be stored in some Apple System Log-like binary format.

How to delete user-defined build settings in Xcode 4.3.1

I have created several user-defined build settings in Xcode 4.3.1. I no longer need these settings and want to delete them, but there doesn't seem to be a way to delete them!
I am aware that these are stored in the project settings (project.pbxproj) file located within the xcodeproj file. But I don't want to edit these in a text editor as there are all sorts of repetitions and guids which I don't understand.
Any suggestions on how I can do this within Xcode? (or have they forgotten to add a "delete" button)
Just figured this out myself: you need to make sure you're at the right scope to be able to delete the setting. If you defined the setting at the project scope, no amount of key-bashing will remove it if you're looking at the target-scope. Remember, targets inherit settings from project scope. That last bit is what I tripped over :)
Try selecting a user-defined setting that you created then hit "Delete" button on your keyboard. That works for me when I encountered the same problem.
On Xcode 6:
Select the row and hit Fn + Delete.
Follow the steps below:
Select Project
Tap on the Info tab
Select Configurations
Select Configuration to remove
Press the Delete button on the keyboard
Removing User-Defined build settings depends on where those settings have been created.
Lets assume that you've created one already and named it as PROJECT_SETTING. In order to check your PROJECT related User-Defined settings, you have to select your project first on the project and targets list, then you should see something like this:
Here you can see only PROJECT related settings, and here you have the
only ability edit/delete PROJECT_SETTING.
Besides that if you set up a TARGET, so can add new User-Defined settings there, that only affects that TARGET scope.
You can edit/delete TARGET_SETTING_1 and TARGET_SETTING_2 here, but
PROJECT_SETTING is read-only, as it is inherited from your
PROJECT settings.
Here you will notice that your TARGET contains your PROJECT User-Defined settings and also your TARGET related User-Defined settings marked as bold letters. This helps you to know which setting can be edited on this level.
You won't be able to delete your settings here if that was created under PROJECT scope, and also editing a PROJECT related User-Defined settings will result a newly created settings that affects only the selected TARGET.
Also if you prefer more visibility on Build Settings, you can select Levels view instead of Combined view, so you should see it more separated:
Select one of them and press keyboard's delete button.
There's a caveat to these answers: If you're using a Build Configuration File (.xcconfig) it doesn't seem possible to delete the user-defined settings generated from these files directly on either the project or target level in the "Build Settings" GUI. You'll have to delete the flag and its value from the configuration file and rebuild the project. If you're using multiple build configuration files that use the same flag, you'll have to delete them from each file.
Although settings that come from these configuration files are displayed in the User Defined build settings section (just like any other user-defined flag that one would create from the GUI), they are not written to the .xcodeproj file like the settings that one adds from the GUI are (which probably prevents them from being able to be deleted from the GUI). They are also not displayed in bold text like these GUI-added settings are.

Change Jenkins default view

I have been trying to follow the instructions on how to change the default view in Jenkins here.
I've created another view that I would like to be the default, but when I go looking for the Default View setting in Manage Jenkins -> Configure System it doesn't seem to be there. Is there something I have to do to make it show up? Or is it tucked away somewhere else?
If someone has it working can they indicate where about in the config screen (immediately before/after something else) so I can double check.
I am using Jenkins 1.447
from comment> When I go to Manage Jenkins -> Configure System and Default View, all our "public" views are listed there in the drop down.
Make sure the view you created isn't just in "My Views" for your user, and is open to everyone.
"Manage Jenkins" > "Configure System" >
The default view option is just after the "SCM checkout retry count" and before "enable security"
See below:
You should not have to change anything to have it show up. You might need more than one view, but it seems you have already created another one...
You can only choose between default views when you have more than one view. So first, create a new view by clicking the '+' mark on the Jenkins dashboard:
Of course, the '+' will only appear if you have permission to create new views.
Now, navigate to Manage Jenkins > Configure System. The Default View option appears. Using this you can select the default view.
The above applies to Jenkins 1.536.
To change the default view in Jenkins go to Jenkins Dashboard:
Select Manage Jenkins --> Configure System --> Default view
Default view will be available after SCM checkout retry count in MAVEN Project Configuration .
Select your applicable View and Save and you're done.

In visual studio 2008, how do I create different debug/release profiles?

We have three servers for each mode:
Development
Testing
Production
Each one of them has different settings for connecting to the database, different base paths for resource accessing etc.
How do I create different debug and release modes for each of those server types and how do I force them to use a different configuration file?
Is there an easy way to switch between them?
Right-click on project->properties->Configuration Manager.
To create solution profile("configuration"):
Click drop-down "Active Solution profiles", select edit.
To create project profile("configuration"):
In "project contexts" "grid", click on dropdown from "Configuration" column, select edit.
To select project profile for solution profile:
Select active solution configuration, then select desired project configurations for each project.
Each profile can have different settings - i.e. target path, include directories, etc, etc - basically everything you can set on property pages can be different for each profile.
They will use same file though.

Resources